forgot this

This commit is contained in:
Fijxu 2023-04-30 21:03:51 -04:00
parent e9083ac308
commit 09fd9e9e1c
1 changed files with 47 additions and 64 deletions

View File

@ -1,87 +1,70 @@
user www-data; user www-data;
worker_processes auto; worker_processes auto;
worker_rlimit_nofile 65535;
pid /run/nginx.pid; pid /run/nginx.pid;
include /etc/nginx/modules-enabled/*.conf; include /etc/nginx/modules-enabled/*.conf;
include /etc/nginx/conf.d/*.conf;
events { events {
worker_connections 768; worker_connections 65535;
# multi_accept on; multi_accept on;
} }
http { http {
access_log off; access_log off;
error_log /dev/null; error_log /dev/null;
## # Basic Settings
# Basic Settings charset utf-8;
## sendfile on;
tcp_nopush on;
tcp_nodelay on;
server_tokens off;
log_not_found off;
types_hash_max_size 4096;
types_hash_bucket_size 64;
sendfile on; # MIME
tcp_nopush on; include mime.types;
types_hash_max_size 2048; default_type application/octet-stream;
server_tokens off;
# server_names_hash_bucket_size 64; # SSL
# server_name_in_redirect off; ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers "ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384";
ssl_prefer_server_ciphers off;
#
ssl_session_timeout 1d;
ssl_session_cache shared:MozSSL:10m;
ssl_session_tickets off;
include /etc/nginx/mime.types; # Diffie-Hellman parameter for DHE ciphersuites
default_type application/octet-stream; ssl_dhparam /etc/nginx/dhparam.pem;
## # HTTP2 Settings
# SSL Settings http2_max_field_size 64k;
## http2_max_header_size 512k;
ssl_protocols TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE # Virtual Host Configs
ssl_prefer_server_ciphers on; include /etc/nginx/sites-enabled/*.conf;
## # DDOS Protection
# Logging Settings limit_conn_zone $binary_remote_addr zone=perip:10m;
## limit_conn perip 100;
access_log /var/log/nginx/access.log; limit_req_zone $binary_remote_addr zone=engine:10m rate=2r/s;
error_log /var/log/nginx/error.log; limit_req_zone $binary_remote_addr zone=static:10m rate=100r/s;
## # reset timed out connections freeing ram
# Gzip Settings reset_timedout_connection on;
## # maximum time between packets the client can pause when sending nginx any data
client_body_timeout 10s;
gzip on; # maximum time the client has to send the entire header to nginx
client_header_timeout 10s;
# gzip_vary on; # timeout which a single keep-alive client connection will stay open
# gzip_proxied any; keepalive_timeout 65s;
# gzip_comp_level 6; # maximum time between packets nginx is allowed to pause when sending the client data
# gzip_buffers 16 8k; send_timeout 10s;
# gzip_http_version 1.1;
# gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
##
# Virtual Host Configs
##
include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
include /etc/nginx/snippets/maps.conf; include /etc/nginx/snippets/maps.conf;
} }
#mail {
# # See sample authentication script at:
# # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
#
# # auth_http localhost/auth.php;
# # pop3_capabilities "TOP" "USER";
# # imap_capabilities "IMAP4rev1" "UIDPLUS";
#
# server {
# listen localhost:110;
# protocol pop3;
# proxy on;
# }
#
# server {
# listen localhost:143;
# protocol imap;
# proxy on;
# }
#}