From 12bbe05df8cf6d3eb804abb290957d597882551d Mon Sep 17 00:00:00 2001 From: MoonTestUse1 Date: Tue, 24 Dec 2024 02:13:29 +0600 Subject: [PATCH] cha25 --- docker/nginx/nginx.conf | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/docker/nginx/nginx.conf b/docker/nginx/nginx.conf index 5d6a9e1..c79483b 100644 --- a/docker/nginx/nginx.conf +++ b/docker/nginx/nginx.conf @@ -1,6 +1,7 @@ +user nginx; worker_processes auto; -pid /var/run/nginx.pid; error_log /var/log/nginx/error.log warn; +pid /var/run/nginx.pid; events { worker_connections 1024; @@ -10,21 +11,15 @@ http { include /etc/nginx/mime.types; default_type application/octet-stream; - log_format main '$remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" "$http_x_forwarded_for"'; + # Basic log format + log_format main '$remote_addr - $remote_user [$time_local] "$request" ' + '$status $body_bytes_sent "$http_referer" ' + '"$http_user_agent" "$http_x_forwarded_for"'; + access_log /var/log/nginx/access.log main; sendfile on; - tcp_nopush on; - tcp_nodelay on; keepalive_timeout 65; - types_hash_max_size 2048; - - gzip on; - gzip_disable "msie6"; - gzip_vary on; - gzip_proxied any; - gzip_comp_level 6; - gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript; include /etc/nginx/conf.d/*.conf; } \ No newline at end of file