From ab07b48bb417e250e33c9ddd24c38c2d852bd97f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn?= Date: Mon, 27 Jul 2020 01:54:35 +0200 Subject: [PATCH] adding nginx --- .gitignore | 4 +- ...7379cb96b8427d61aa39b73678b202900cb648.php | 9 ---- ...3a641a10e5f3da2806ddee53e0522e9158ee7b.php | 7 --- ...f5c7f4e7eb0830bf2cbb7d8c98c9e7e3eda420.php | 44 ------------------- ...be4cd44c7bf959a77084ac66540007a10ae7f2.php | 44 ------------------- ...5fb649a0065d8271813d9667d51f50825d6579.php | 16 ------- ...faad602c007cdd0b7e6f2115872a4a74a46e03.php | 9 ---- ...33776c0af644e989accce92812804c9542ae25.php | 44 ------------------- ...3cb35f6a6aa916c3116d6254ed92e718b1cafb.php | 9 ---- ...59350e6c9ffc48e248d8248ac6e8cc234e8172.php | 44 ------------------- 10 files changed, 2 insertions(+), 228 deletions(-) delete mode 100644 storage/cache/887379cb96b8427d61aa39b73678b202900cb648.php delete mode 100644 storage/cache/8f3a641a10e5f3da2806ddee53e0522e9158ee7b.php delete mode 100644 storage/cache/97f5c7f4e7eb0830bf2cbb7d8c98c9e7e3eda420.php delete mode 100644 storage/cache/b8be4cd44c7bf959a77084ac66540007a10ae7f2.php delete mode 100644 storage/cache/c25fb649a0065d8271813d9667d51f50825d6579.php delete mode 100644 storage/cache/d3faad602c007cdd0b7e6f2115872a4a74a46e03.php delete mode 100644 storage/cache/db33776c0af644e989accce92812804c9542ae25.php delete mode 100644 storage/cache/ea3cb35f6a6aa916c3116d6254ed92e718b1cafb.php delete mode 100644 storage/cache/f759350e6c9ffc48e248d8248ac6e8cc234e8172.php diff --git a/.gitignore b/.gitignore index b27dc07..412d41d 100644 --- a/.gitignore +++ b/.gitignore @@ -8,8 +8,8 @@ database/database.sqlite storage/logs/* -storage/tmp -!storage/tmp/.gitkeep +storage/cache +!storage/cache/.gitkeep resources/templates/nginx !resources/templates/nginx/.gitkeep \ No newline at end of file diff --git a/storage/cache/887379cb96b8427d61aa39b73678b202900cb648.php b/storage/cache/887379cb96b8427d61aa39b73678b202900cb648.php deleted file mode 100644 index cf09a80..0000000 --- a/storage/cache/887379cb96b8427d61aa39b73678b202900cb648.php +++ /dev/null @@ -1,9 +0,0 @@ -server_name ; - -# include snippets -include /etc/nginx/snippets/deny.conf; -include /etc/nginx/snippets/expires.conf; - -# logs -access_log /var/log/nginx/.access.log; -error_log /var/log/nginx/.error.log; \ No newline at end of file diff --git a/storage/cache/8f3a641a10e5f3da2806ddee53e0522e9158ee7b.php b/storage/cache/8f3a641a10e5f3da2806ddee53e0522e9158ee7b.php deleted file mode 100644 index 868921b..0000000 --- a/storage/cache/8f3a641a10e5f3da2806ddee53e0522e9158ee7b.php +++ /dev/null @@ -1,7 +0,0 @@ -server { - location / { - try_files $uri $uri/ /index.php; - } -} - - \ No newline at end of file diff --git a/storage/cache/97f5c7f4e7eb0830bf2cbb7d8c98c9e7e3eda420.php b/storage/cache/97f5c7f4e7eb0830bf2cbb7d8c98c9e7e3eda420.php deleted file mode 100644 index 22e8da0..0000000 --- a/storage/cache/97f5c7f4e7eb0830bf2cbb7d8c98c9e7e3eda420.php +++ /dev/null @@ -1,44 +0,0 @@ -server { - listen 80; - listen [::]:80; - server_name www. ; - return 301 https://$request_uri; -} - - -server { - listen 443 ssl http2; - listen [::]:443 ssl http2; - - ssl_certificate /etc/letsencrypt/live/www./fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live/www./privkey.pem; - - include snippets/ssl-params.conf; - include /etc/nginx/snippets/secure-headers.conf; - - server_name www.; - return 301 https://$request_uri; -} - - -server { - listen 443 ssl http2; - listen [::]:443 ssl http2; - - ssl_certificate /etc/letsencrypt/live//fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live//privkey.pem; - - add_header Content-Security-Policy " - default-src 'self'; - font-src 'self'; - style-src 'self'; - img-src 'self'; - base-uri 'self'; - form-action 'self'; - frame-ancestors 'self'; - "; - - make('partials.default', ['domain' => $domain], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> - - yieldContent('server'); ?> -} \ No newline at end of file diff --git a/storage/cache/b8be4cd44c7bf959a77084ac66540007a10ae7f2.php b/storage/cache/b8be4cd44c7bf959a77084ac66540007a10ae7f2.php deleted file mode 100644 index 61cbd7f..0000000 --- a/storage/cache/b8be4cd44c7bf959a77084ac66540007a10ae7f2.php +++ /dev/null @@ -1,44 +0,0 @@ -startSection('server'); ?> -root ; -index ; - -# rewrite -location / { - try_files $uri $uri/ /index.php?$args; -} - -location = /favicon.ico { - log_not_found off; - access_log off; -} - -location = /robots.txt { - allow all; - log_not_found off; - access_log off; -} - -location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { - expires max; - log_not_found off; -} - -location ~ /\. { - deny all; -} - -location ~* /(?:uploads|files)/.*\.php$ { - deny all; -} - -# php-fpm configuration. -location ~ \.php(/|$) { - fastcgi_split_path_info ^(.+\.php)(.*)$; - fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; - fastcgi_index index.php; - fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name; - fastcgi_param DOCUMENT_ROOT $realpath_root; - include /etc/nginx/fastcgi_params; -} -stopSection(); ?> -make($ssl ? 'layouts.ssl' : 'layouts.no-ssl', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> \ No newline at end of file diff --git a/storage/cache/c25fb649a0065d8271813d9667d51f50825d6579.php b/storage/cache/c25fb649a0065d8271813d9667d51f50825d6579.php deleted file mode 100644 index 3dc0259..0000000 --- a/storage/cache/c25fb649a0065d8271813d9667d51f50825d6579.php +++ /dev/null @@ -1,16 +0,0 @@ -server { - listen 80; - listen [::]:80; - server_name www. ; - return 301 http://$request_uri; -} - -server { - listen 80; - listen [::]:80; - - make('partials.default', ['domain' => $domain], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> - - startSection('server'); ?> - yieldSection(); ?> -} \ No newline at end of file diff --git a/storage/cache/d3faad602c007cdd0b7e6f2115872a4a74a46e03.php b/storage/cache/d3faad602c007cdd0b7e6f2115872a4a74a46e03.php deleted file mode 100644 index a6c69de..0000000 --- a/storage/cache/d3faad602c007cdd0b7e6f2115872a4a74a46e03.php +++ /dev/null @@ -1,9 +0,0 @@ -server_name ; - -# include snippets -include /etc/nginx/snippets/deny.conf; -include /etc/nginx/snippets/expires.conf; - -# logs -access_log /var/log/nginx/.access.log; -error_log /var/log/nginx/.error.log; \ No newline at end of file diff --git a/storage/cache/db33776c0af644e989accce92812804c9542ae25.php b/storage/cache/db33776c0af644e989accce92812804c9542ae25.php deleted file mode 100644 index 7916b86..0000000 --- a/storage/cache/db33776c0af644e989accce92812804c9542ae25.php +++ /dev/null @@ -1,44 +0,0 @@ -server { - listen 80; - listen [::]:80; - server_name www. ; - return 301 https://$request_uri; -} - - -server { - listen 443 ssl http2; - listen [::]:443 ssl http2; - - ssl_certificate /etc/letsencrypt/live/www./fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live/www./privkey.pem; - - include snippets/ssl-params.conf; - include /etc/nginx/snippets/secure-headers.conf; - - server_name www.; - return 301 https://$request_uri; -} - - -server { - listen 443 ssl http2; - listen [::]:443 ssl http2; - - ssl_certificate /etc/letsencrypt/live//fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live//privkey.pem; - - add_header Content-Security-Policy " - default-src 'self'; - font-src 'self'; - style-src 'self'; - img-src 'self'; - base-uri 'self'; - form-action 'self'; - frame-ancestors 'self'; - "; - - make('partials.default', ['domain' => $domain], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> - - yieldContent('server'); ?> -} \ No newline at end of file diff --git a/storage/cache/ea3cb35f6a6aa916c3116d6254ed92e718b1cafb.php b/storage/cache/ea3cb35f6a6aa916c3116d6254ed92e718b1cafb.php deleted file mode 100644 index 853153a..0000000 --- a/storage/cache/ea3cb35f6a6aa916c3116d6254ed92e718b1cafb.php +++ /dev/null @@ -1,9 +0,0 @@ -startSection('server'); ?> -root ; -index ; - -location / { - try_files $uri $uri/ /index.php; -} -stopSection(); ?> -make($ssl ? 'layouts.ssl' : 'layouts.no-ssl', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> \ No newline at end of file diff --git a/storage/cache/f759350e6c9ffc48e248d8248ac6e8cc234e8172.php b/storage/cache/f759350e6c9ffc48e248d8248ac6e8cc234e8172.php deleted file mode 100644 index f228787..0000000 --- a/storage/cache/f759350e6c9ffc48e248d8248ac6e8cc234e8172.php +++ /dev/null @@ -1,44 +0,0 @@ -startSection('server'); ?> -root ; -index ; - -# rewrite -location / { - try_files $uri $uri/ /index.php?$args; -} - -location = /favicon.ico { - log_not_found off; - access_log off; -} - -location = /robots.txt { - allow all; - log_not_found off; - access_log off; -} - -location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { - expires max; - log_not_found off; -} - -location ~ /\. { - deny all; -} - -location ~* /(?:uploads|files)/.*\.php$ { - deny all; -} - -# php-fpm configuration. -location ~ \.php(/|$) { - fastcgi_split_path_info ^(.+\.php)(.*)$; - fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; - fastcgi_index index.php; - fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name; - fastcgi_param DOCUMENT_ROOT $realpath_root; - include /etc/nginx/fastcgi_params; -} -stopSection(); ?> -make($ssl ? 'layouts.ssl' : 'layouts.no-ssl', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?> \ No newline at end of file