Files
nginx-proxy-manager/rootfs/usr/local/nginx/conf/nginx.conf
Zoey 19a304d9ce init
Signed-off-by: Zoey <zoey@z0ey.de>
2022-12-17 14:25:32 +01:00

103 lines
2.2 KiB
Nginx Configuration File

user root;
daemon off;
pcre_jit on;
worker_processes auto;
error_log stderr;
# Custom
include /data/nginx/custom/root.conf;
events {
use epoll;
# Custom
include /data/nginx/custom/events.conf;
}
http {
log_not_found off;
access_log /dev/null;
include mime.types;
default_type text/plain;
server_tokens build;
aio threads;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
client_max_body_size 0;
gzip on;
gunzip on;
gzip_vary on;
gzip_types *;
gzip_proxied any;
gzip_comp_level 9;
resolver localhost;
index index.html Index.html;
error_page 404 =307 $scheme://$host:$server_port;
error_page 497 =301 https://$host:$server_port$request_uri;
# Default upstream scheme
map $host $forward_scheme {
default http;
}
# Websocket
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
# Fancy Index
fancyindex on;
fancyindex_localtime on;
fancyindex_show_path on;
fancyindex_exact_size off;
fancyindex_default_sort name;
fancyindex_show_dotfiles off;
fancyindex_hide_symlinks off;
fancyindex_hide_parent_dir off;
fancyindex_directories_first on;
fancyindex_time_format "%d-%m-%Y %T";
fancyindex_ignore "nft";
fancyindex_header "/nftd/header.html";
fancyindex_footer "/nftd/footer.html";
# Real IP Determination
real_ip_recursive on;
set_real_ip_from 10.0.0.0/8;
set_real_ip_from 172.16.0.0/12;
set_real_ip_from 192.168.0.0/16;
set_real_ip_from 169.254.0.0/16;
set_real_ip_from fc00::/7;
set_real_ip_from fec0::/10;
include conf.d/include/ip_ranges.conf;
include /data/nginx/default.conf;
include conf.d/*.conf;
# Custom
include /data/nginx/custom/http_top.conf;
# Files generated by NPM
include /data/nginx/proxy_host/*.conf;
include /data/nginx/redirection_host/*.conf;
include /data/nginx/dead_host/*.conf;
# Custom
include /data/nginx/custom/http.conf;
}
stream {
# Files generated by NPM
include /data/nginx/stream/*.conf;
# Custom
include /data/nginx/custom/stream.conf;
}