C11
This commit is contained in:
+24
-16
@@ -29,6 +29,30 @@ http {
|
|||||||
|
|
||||||
server {
|
server {
|
||||||
listen 80;
|
listen 80;
|
||||||
|
server_name _;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
return 301 https://$host:8443$request_uri;
|
||||||
|
}
|
||||||
|
|
||||||
|
location = /healthz {
|
||||||
|
default_type text/plain;
|
||||||
|
return 200 "ok\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
location = /internal/status {
|
||||||
|
access_log off;
|
||||||
|
default_type text/plain;
|
||||||
|
|
||||||
|
if ($remote_addr != 127.0.0.1) {
|
||||||
|
return 403;
|
||||||
|
}
|
||||||
|
|
||||||
|
return 200 "internal ok\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
listen 443 ssl;
|
listen 443 ssl;
|
||||||
server_name localhost;
|
server_name localhost;
|
||||||
ssl_certificate /etc/nginx/certs/localhost.crt;
|
ssl_certificate /etc/nginx/certs/localhost.crt;
|
||||||
@@ -71,21 +95,5 @@ http {
|
|||||||
proxy_set_header X-Forwarded-Proto http;
|
proxy_set_header X-Forwarded-Proto http;
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
}
|
}
|
||||||
|
|
||||||
location = /healthz {
|
|
||||||
default_type text/plain;
|
|
||||||
return 200 "ok\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
location = /internal/status {
|
|
||||||
access_log off;
|
|
||||||
default_type text/plain;
|
|
||||||
|
|
||||||
if ($remote_addr != 127.0.0.1) {
|
|
||||||
return 403;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 200 "internal ok\n";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user