configuration/configs/nginx.config.conf
configuration/configs/nginx.config.conf is a file in Bane's Lab Server. 83 lines of code and 0 definitions.
load_module modules/ngx_http_brotli_filter_module.so;
load_module modules/ngx_http_brotli_static_module.so;
user www-data;
worker_processes auto;
worker_cpu_affinity auto;
pid /run/nginx.pid;
error_log /var/log/nginx/error.log;
include /etc/nginx/modules-enabled/*.conf;
events {
worker_connections 768;
}
http {
sendfile on;
tcp_nopush on;
tcp_nodelay on;
types_hash_max_size 2048;
server_tokens off;
more_clear_headers Server;
include /etc/nginx/mime.types;
default_type application/octet-stream;
client_max_body_size 10m;
client_body_timeout 10s;
client_header_timeout 10s;
limit_req_zone $binary_remote_addr zone=general:10m rate=100r/s;
limit_req_zone $binary_remote_addr zone=api:10m rate=200r/s;
limit_req_zone $binary_remote_addr zone=dashboard:10m rate=100r/s;
limit_conn_zone $binary_remote_addr zone=conn_limit:10m;
map $arg_tab $legacy_tab {
default "/$arg_tab";
"" "";
introduction "";
}
map $arg_section $legacy_section {
default "#$arg_section";
"" "";
}
map $http_accept $accepts_markdown {
default 0;
~text/markdown 1;
}
map "$accepts_markdown$uri" $markdown_route {
default 0;
"~^1/[^.]*$" 1;
}
log_format security '$remote_addr - $remote_user [$time_local] '
'"$request" $status $body_bytes_sent '
'"$http_referer" "$http_user_agent" '
'rt=$request_time uct="$upstream_connect_time" '
'uht="$upstream_header_time" urt="$upstream_response_time" '
'rid=$request_id';
ssl_protocols TLSv1.2 TLSv1.3;
ssl_prefer_server_ciphers on;
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;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
ssl_session_tickets off;
ssl_conf_command SignatureAlgorithms ECDSA+SHA256:ECDSA+SHA384:ECDSA+SHA512:ed25519:ed448:RSA-PSS+SHA256:RSA-PSS+SHA384:RSA-PSS+SHA512:RSA+SHA256:RSA+SHA384:RSA+SHA512;
access_log /var/log/nginx/access.log;
gzip on;
gzip_vary on;
gzip_proxied any;
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_min_length 256;
gzip_types
text/plain
text/css
text/xml
text/javascript
application/json
application/javascript
application/x-javascript
application/xml
application/xml+rss
application/vnd.ms-fontobject
application/x-font-ttf
font/opentype
image/svg+xml
image/x-icon;
include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
}