podman-services/etc/nginx/sites-available/chat.theribbles.org

48 lines
1.2 KiB
Org Mode
Raw Permalink Normal View History

2024-02-21 12:37:30 -08:00
server {
root /var/www/element;
# Add index.php to the list if you are using PHP
index index.html;
server_name chat.theribbles.org;
access_log /var/log/nginx/chat.theribbles.org-access.log;
error_log /var/log/nginx/chat.theribbles.org-error.log debug;
location = /index.html {
add_header Cache-Control "no-cache";
}
location = /version {
add_header Cache-Control "no-cache";
}
# covers config.json and config.hostname.json requests as it is prefix.
location /config {
add_header Cache-Control "no-cache";
}
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
listen 443 ssl http2; # manually changed, but added by Certbot
ssl_certificate /etc/letsencrypt/live/theribbles.org/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/theribbles.org/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 = chat.theribbles.org) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
listen [::]:80;
server_name chat.theribbles.org;
return 404; # managed by Certbot
}