Spotter-VM/vm/etc/nginx/conf.d/default.conf

62 lines
1.1 KiB
Plaintext
Raw Normal View History

2018-10-31 22:27:17 +01:00
server {
listen [::]:80 default_server ipv6only=off;
location / {
return 301 https://$host:443$request_uri;
}
location /.well-known/acme-challenge/ {
root /etc/acme.sh.d;
}
location = /vm-ping {
add_header Content-Type text/plain;
return 200 "vm-pong";
}
}
server {
listen [::]:443 ssl http2 default_server ipv6only=off;
location / {
proxy_pass http://127.0.0.1:8080;
}
location /static {
2018-11-01 12:51:06 +01:00
root /usr/share/vmmgr;
2018-10-31 22:27:17 +01:00
}
error_page 502 /502.html;
location = /502.html {
2018-11-01 12:51:06 +01:00
root /usr/share/vmmgr/templates;
2018-10-31 22:27:17 +01:00
}
location = /vm-ping {
add_header Content-Type text/plain;
return 200 "vm-pong";
}
}
2018-11-04 19:50:48 +01:00
server {
listen [::]:443 ssl http2;
server_name ~^(.*)\.spotter\.vm$;
location / {
return 503;
}
location /static {
root /usr/share/vmmgr;
}
error_page 503 /503.html;
location = /503.html {
root /usr/share/vmmgr/templates;
}
location = /vm-ping {
add_header Content-Type text/plain;
return 200 "vm-pong";
}
}