From 24e7fad8201a2136813d3abb4ed432e8bcbee9b9 Mon Sep 17 00:00:00 2001 From: sabelo Date: Mon, 29 Jul 2024 01:26:11 -0300 Subject: [PATCH] improves nginx conf to deploy on coolify --- nginx.conf | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/nginx.conf b/nginx.conf index 5ed0f9d..db1d9a0 100644 --- a/nginx.conf +++ b/nginx.conf @@ -21,23 +21,24 @@ http { tcp_nopush on; server_names_hash_bucket_size 128; # this seems to be required for some vhosts -server { - listen 80; - server_name ggdworkshop.cmat.edu.uy; - index index.php index.html index.html; - error_log /var/log/nginx/ggdworkshop/error.log; - access_log /var/log/nginx/ggdworkshop/access.log; - root /usr/share/nginx/sites/ggdworkshop/public; - location / { - try_files $uri /index.php$is_args$args; - } - location ~ \.php$ { - try_files $uri =404; - fastcgi_split_path_info ^(.+\.php)(/.+)$; - fastcgi_pass 127.0.0.1:9000; - fastcgi_index index.php; - fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; - include fastcgi_params; - } -} + server { + listen 80; + server_name localhost; + index index.php index.html index.html; + add_header X-Frame-Options "SAMEORIGIN"; + add_header X-Content-Type-Options "nosniff"; + charset utf-8; + root /app/public; + location / { + try_files $uri /index.php$is_args$args; + } + location ~ \.php$ { + try_files $uri =404; + fastcgi_split_path_info ^(.+\.php)(/.+)$; + fastcgi_pass 127.0.0.1:9000; + fastcgi_index index.php; + fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; + include fastcgi_params; + } + } } \ No newline at end of file