From 3dddde75c8ba02f8b5365c1499b503c2215a2073 Mon Sep 17 00:00:00 2001 From: Jan Tuomi Date: Fri, 16 Jan 2026 15:12:55 +0200 Subject: Fix /feed.xml, https upgrade --- templates/homepage/usr_local_etc_nginx_nginx.conf.j2 | 5 +++-- templates/ingress/usr_local_etc_nginx_nginx.conf.j2 | 10 ++++++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/templates/homepage/usr_local_etc_nginx_nginx.conf.j2 b/templates/homepage/usr_local_etc_nginx_nginx.conf.j2 index 079f89d..ee45405 100644 --- a/templates/homepage/usr_local_etc_nginx_nginx.conf.j2 +++ b/templates/homepage/usr_local_etc_nginx_nginx.conf.j2 @@ -41,10 +41,11 @@ http { # Migration redirects from legacy site location ~ ^/archive(?:/(.*))?$ { - return 302 /posts/$1$is_args$args; + return 307 /posts/$1$is_args$args; } location = /feed.xml { - return 302 /atom.xml; + # Serve atom.xml content at the legacy feed.xml URL (no redirect) + rewrite ^ /atom.xml break; } location / { diff --git a/templates/ingress/usr_local_etc_nginx_nginx.conf.j2 b/templates/ingress/usr_local_etc_nginx_nginx.conf.j2 index 1e58153..16299ef 100644 --- a/templates/ingress/usr_local_etc_nginx_nginx.conf.j2 +++ b/templates/ingress/usr_local_etc_nginx_nginx.conf.j2 @@ -41,6 +41,16 @@ http { } {% for route in ingress_routes -%} + server { + listen 80; + listen [::]:80; + server_name {{ route.host }}; + + include /usr/local/etc/nginx/snippets/ban.inc; + + return 307 https://$host$request_uri; + } + server { server_name {{ route.host }}; http2 on; -- cgit v1.3