From 6ab77b1b4bad609cd7f6c2f3ffc95c75f670066a Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Sun, 4 Aug 2019 17:26:56 +0200 Subject: [PATCH] nginx/configure/unindent --- in/public/web/nginx/configure.rst | 90 ++++++++++++++++--------------- 1 file changed, 46 insertions(+), 44 deletions(-) diff --git a/in/public/web/nginx/configure.rst b/in/public/web/nginx/configure.rst index 7b16578..0c7310d 100644 --- a/in/public/web/nginx/configure.rst +++ b/in/public/web/nginx/configure.rst @@ -11,66 +11,68 @@ Configure worker_processes auto; events { - multi_accept off; - worker_connections 512; + multi_accept off; + worker_connections 512; } http { - # General - keepalive_timeout 60; - sendfile on; - server_tokens off; - tcp_nopush on; - tcp_nodelay on; - types_hash_max_size 2048; + # General - # Names + keepalive_timeout 60; + sendfile on; + server_tokens off; + tcp_nopush on; + tcp_nodelay on; + types_hash_max_size 2048; - server_name_in_redirect off; - server_names_hash_bucket_size 128; + # Names - # File types + server_name_in_redirect off; + server_names_hash_bucket_size 128; - include /etc/nginx/mime.types; - default_type application/octet-stream; + # File types - # Security + include /etc/nginx/mime.types; + default_type application/octet-stream; - ssl_buffer_size 8k; - ssl_ciphers "ECDHE-RSA-AES256-GCM-SHA384,ECDHE-ECDSA-AES256-GCM-SHA384,ECDHE-RSA-AES256-SHA384,ECDHE-ECDSA-AES256-SHA384,ECDHE-RSA-AES256-SHA,ECDHE-ECDSA-AES256-SHA,DHE-DSS-AES256-GCM-SHA384,DHE-RSA-AES256-GCM-SHA384,DHE-RSA-AES256-SHA256,DHE-DSS-AES256-SHA256,DHE-RSA-AES256-SHA,DHE-DSS-AES256-SHA"; - ssl_dhparam /etc/nginx/dhparam; - ssl_ecdh_curve secp384r1; - ssl_prefer_server_ciphers on; - ssl_protocols TLSv1.2; - ssl_session_cache shared:ssl_session_cache:16m; - ssl_session_timeout 15m; + # Security - # Log + ssl_buffer_size 8k; + ssl_ciphers "ECDHE-RSA-AES256-GCM-SHA384,ECDHE-ECDSA-AES256-GCM-SHA384,ECDHE-RSA-AES256-SHA384,ECDHE-ECDSA-AES256-SHA384,ECDHE-RSA-AES256-SHA,ECDHE-ECDSA-AES256-SHA,DHE-DSS-AES256-GCM-SHA384,DHE-RSA-AES256-GCM-SHA384,DHE-RSA-AES256-SHA256,DHE-DSS-AES256-SHA256,DHE-RSA-AES256-SHA,DHE-DSS-AES256-SHA"; + ssl_dhparam /etc/nginx/dhparam; + ssl_ecdh_curve secp384r1; + ssl_prefer_server_ciphers on; + ssl_protocols TLSv1.2; + ssl_session_cache shared:ssl_session_cache:16m; + ssl_session_timeout 15m; - access_log /var/log/nginx/access.log; - error_log /var/log/nginx/error.log; + # Log - # Compression + access_log /var/log/nginx/access.log; + error_log /var/log/nginx/error.log; - gzip on; - gzip_buffers 32 8k; - gzip_comp_level 5; - gzip_http_version 1.1; - gzip_proxied any; - gzip_types *; - gzip_vary off; + # Compression - # Misc + gzip on; + gzip_buffers 32 8k; + gzip_comp_level 5; + gzip_http_version 1.1; + gzip_proxied any; + gzip_types *; + gzip_vary off; - add_header Strict-Transport-Security max-age=31557600; - client_max_body_size 16m; - index index.html; - proxy_pass_request_body on; - proxy_pass_request_headers on; - proxy_redirect off; + # Misc - # Includes + add_header Strict-Transport-Security max-age=31557600; + client_max_body_size 16m; + index index.html; + proxy_pass_request_body on; + proxy_pass_request_headers on; + proxy_redirect off; + + # Includes + + include /etc/nginx/sites-enabled/*; - include /etc/nginx/sites-enabled/*; }