generated from nhcarrigan/template
fc252e28e2
Adds a deny-dotfiles snippet that returns 403 for any URI matching /\. (e.g. .gitconfig, .env, .git/) and includes it in every server block.
43 lines
1.2 KiB
Plaintext
43 lines
1.2 KiB
Plaintext
# Mommy bot suite: mommy-bot Discord bot, mommy-slack Slack bot, mommy web front-end.
|
|
server {
|
|
listen 443 ssl;
|
|
server_name mommy-bot.nhcarrigan.com;
|
|
ssl_certificate /etc/letsencrypt/live/mommy-bot.nhcarrigan.com/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/mommy-bot.nhcarrigan.com/privkey.pem;
|
|
|
|
location / {
|
|
proxy_set_header Host $host;
|
|
proxy_pass http://127.0.0.1:8009;
|
|
proxy_redirect off;
|
|
}
|
|
include /etc/nginx/snippets/deny-dotfiles.conf;
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl;
|
|
server_name mommy-slack.nhcarrigan.com;
|
|
ssl_certificate /etc/letsencrypt/live/mommy-slack.nhcarrigan.com/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/mommy-slack.nhcarrigan.com/privkey.pem;
|
|
|
|
location / {
|
|
proxy_set_header Host $host;
|
|
proxy_pass http://127.0.0.1:8010;
|
|
proxy_redirect off;
|
|
}
|
|
include /etc/nginx/snippets/deny-dotfiles.conf;
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl;
|
|
server_name mommy.nhcarrigan.com;
|
|
ssl_certificate /etc/letsencrypt/live/mommy.nhcarrigan.com/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/mommy.nhcarrigan.com/privkey.pem;
|
|
|
|
location / {
|
|
proxy_set_header Host $host;
|
|
proxy_pass http://127.0.0.1:8008;
|
|
proxy_redirect off;
|
|
}
|
|
include /etc/nginx/snippets/deny-dotfiles.conf;
|
|
}
|