File nginx-conf.patch of Package nginx
diff -Pdpru nginx-1.27.4.orig/conf/nginx.conf nginx-1.27.4/conf/nginx.conf
--- nginx-1.27.4.orig/conf/nginx.conf 2025-02-05 14:06:32.000000000 +0300
+++ nginx-1.27.4/conf/nginx.conf 2025-03-30 05:11:05.303755904 +0300
@@ -1,117 +1,130 @@
+#user nginx nginx;
+#worker_processes 1;
+#pcre_jit off;
-#user nobody;
-worker_processes 1;
-
-#error_log logs/error.log;
-#error_log logs/error.log notice;
-#error_log logs/error.log info;
+# load_module #LIBDIR#/nginx/modules/ngx_http_echo_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_fancyindex_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_geoip2_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_image_filter_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_lua_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_perl_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_http_xslt_filter_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_mail_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_stream_geoip2_module.so;
+# load_module #LIBDIR#/nginx/modules/ngx_stream_module.so;
-#pid logs/nginx.pid;
+#error_log /var/log/nginx/error.log;
+#error_log /var/log/nginx/error.log notice;
+#error_log /var/log/nginx/error.log info;
+#pid /run/nginx.pid;
events {
- worker_connections 1024;
+ multi_accept on;
+ worker_connections 1024;
}
-
http {
- include 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"';
+ include mime.types;
+ default_type application/octet-stream;
- #access_log logs/access.log main;
+ #log_format main '$time_local - $http_host - $remote_addr - $status "$request" $body_bytes_sent - $http_referer - "$http_user_agent"';
+ #access_log /var/log/nginx/access.log main;
- sendfile on;
- #tcp_nopush on;
+ http2 on;
+ sendfile on;
+ #tcp_nopush on;
+ #tcp_nodelay on;
- #keepalive_timeout 0;
- keepalive_timeout 65;
+ #keepalive_timeout 0;
+ keepalive_timeout 70;
- #gzip on;
+ #gzip on;
- server {
- listen 80;
- server_name localhost;
+ include conf.d/*.conf;
- #charset koi8-r;
+ server {
+ listen 80;
+ server_name localhost;
- #access_log logs/host.access.log main;
+ #access_log /var/log/nginx/host.access.log main;
- location / {
- root html;
- index index.html index.htm;
- }
+ location / {
+ root /srv/www/htdocs;
+ index index.html index.htm;
+ }
- #error_page 404 /404.html;
+ #error_page 404 /404.html;
- # redirect server error pages to the static page /50x.html
- #
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- root html;
- }
+ # redirect server error pages to the static page /50x.html
+ #
+ #error_page 500 502 503 504 /50x.html;
+ #location = /50x.html {
+ # root /srv/www/htdocs;
+ #}
- # proxy the PHP scripts to Apache listening on 127.0.0.1:80
- #
- #location ~ \.php$ {
- # proxy_pass http://127.0.0.1;
- #}
+ # proxy the PHP scripts to Apache listening on 127.0.0.1:80
+ #
+ #location ~ \.php$ {
+ # proxy_pass http://127.0.0.1;
+ #}
- # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
- #
- #location ~ \.php$ {
- # root html;
- # fastcgi_pass 127.0.0.1:9000;
- # fastcgi_index index.php;
- # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
- # include fastcgi_params;
- #}
+ # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
+ #
+ #location ~ \.php$ {
+ # root /srv/www/htdocs;
+ # fastcgi_pass 127.0.0.1:9000;
+ # fastcgi_index index.php;
+ # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
+ # include fastcgi_params;
+ #}
- # deny access to .htaccess files, if Apache's document root
- # concurs with nginx's one
- #
- #location ~ /\.ht {
- # deny all;
- #}
- }
+ # deny access to hidden files
+ #
+ #location ^~ /. {
+ # deny all;
+ #}
+ }
+ # another virtual host using mix of IP-, name-, and port-based configuration
+ #
+ #server {
+ # listen 8000;
+ # listen somename:8080;
+ # server_name somename alias another.alias;
+ # location / {
+ # root /srv/www/htdocs;
+ # index index.html index.htm;
+ # }
+ #}
- # another virtual host using mix of IP-, name-, and port-based configuration
- #
- #server {
- # listen 8000;
- # listen somename:8080;
- # server_name somename alias another.alias;
+ # HTTPS server
+ #
+ #server {
+ # listen 443 ssl;
+ # server_name localhost;
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
+ # ssl_certificate cert.crt;
+ # ssl_certificate_key cert.key;
+ # ssl_protocols TLSv1.2 TLSv1.3;
- # HTTPS server
- #
- #server {
- # listen 443 ssl;
- # server_name localhost;
+ # ssl_ciphers ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384;
+ # ssl_conf_command Ciphersuites TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384;
+ # ssl_prefer_server_ciphers on;
- # ssl_certificate cert.pem;
- # ssl_certificate_key cert.key;
+ # ssl_ecdh_curve prime256v1;
- # ssl_session_cache shared:SSL:1m;
- # ssl_session_timeout 5m;
+ # ssl_early_data on;
- # ssl_ciphers HIGH:!aNULL:!MD5;
- # ssl_prefer_server_ciphers on;
+ # ssl_session_cache shared:SSL:10m;
+ # ssl_session_timeout 10m;
- # location / {
- # root html;
- # index index.html index.htm;
- # }
- #}
+ # location / {
+ # root /srv/www/htdocs;
+ # index index.html index.htm;
+ # }
+ #
+ include vhosts.d/*.conf;
}