45 lines
1.2 KiB
Text
Executable file
45 lines
1.2 KiB
Text
Executable file
server {
|
|
access_log /var/log/nginx/mpd.ayaya.beauty.log combined;
|
|
error_log /var/log/nginx/mpd.ayaya.beauty.error.log;
|
|
|
|
server_name mpd.ayaya.beauty;
|
|
include configs/general.conf;
|
|
include configs/securityheaders.conf;
|
|
|
|
location / {
|
|
proxy_pass http://192.168.1.2:40420;
|
|
#include configs/proxyheaders.conf;
|
|
proxy_connect_timeout 1;
|
|
proxy_send_timeout 1;
|
|
proxy_read_timeout 1;
|
|
}
|
|
location /status {
|
|
# Turn on stats
|
|
stub_status on;
|
|
access_log off;
|
|
# only allow access from 192.168.1.5 #
|
|
allow 192.168.1.2;
|
|
deny all;
|
|
}
|
|
|
|
listen 443 http3;
|
|
listen 443 http2 ssl; # managed by Certbot
|
|
ssl_certificate /etc/letsencrypt/live/mpd.ayaya.beauty/fullchain.pem; # managed by Certbot
|
|
ssl_certificate_key /etc/letsencrypt/live/mpd.ayaya.beauty/privkey.pem; # managed by Certbot
|
|
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
|
|
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
|
|
|
|
}
|
|
server {
|
|
if ($host = mpd.ayaya.beauty) {
|
|
return 301 https://$host$request_uri;
|
|
} # managed by Certbot
|
|
|
|
|
|
server_name mpd.ayaya.beauty;
|
|
|
|
listen 80;
|
|
return 404; # managed by Certbot
|
|
|
|
|
|
}
|