mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-01-29 00:51:53 +08:00
nginx: configurable listen ip addresses
Based by idea of pikvm/pikvm#189
This commit is contained in:
@@ -39,9 +39,9 @@ http {
|
||||
% if https_enabled:
|
||||
|
||||
server {
|
||||
listen ${http_port};
|
||||
listen ${http_ipv4}:${http_port};
|
||||
% if ipv6_enabled:
|
||||
listen [::]:${http_port};
|
||||
listen [${http_ipv6}]:${http_port};
|
||||
% endif
|
||||
include /etc/kvmd/nginx/certbot.ctx-server.conf;
|
||||
location / {
|
||||
@@ -54,9 +54,9 @@ http {
|
||||
}
|
||||
|
||||
server {
|
||||
listen ${https_port} ssl;
|
||||
listen ${https_ipv4}:${https_port} ssl;
|
||||
% if ipv6_enabled:
|
||||
listen [::]:${https_port} ssl;
|
||||
listen [${https_ipv6}]:${https_port} ssl;
|
||||
% endif
|
||||
http2 on;
|
||||
include /etc/kvmd/nginx/ssl.conf;
|
||||
@@ -67,9 +67,9 @@ http {
|
||||
% else:
|
||||
|
||||
server {
|
||||
listen ${http_port};
|
||||
listen ${http_ipv4}:${http_port};
|
||||
% if ipv6_enabled:
|
||||
listen [::]:${http_port};
|
||||
listen [${http_ipv6}]:${http_port};
|
||||
% endif
|
||||
include /etc/kvmd/nginx/certbot.ctx-server.conf;
|
||||
include /etc/kvmd/nginx/kvmd.ctx-server.conf;
|
||||
|
||||
Reference in New Issue
Block a user