From c0d06f4a178c8293f503c72b5426f8668043f196 Mon Sep 17 00:00:00 2001 From: Mieszko Makuch Date: Tue, 28 Jul 2026 19:24:34 +0200 Subject: [PATCH] fix: /admin redirect loses port behind tunnel/proxy (absolute_redirect off, trailing slash in footer link) --- deploy/nginx.conf | 4 ++++ src/layouts/Base.astro | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/deploy/nginx.conf b/deploy/nginx.conf index 05bf842..9e30669 100644 --- a/deploy/nginx.conf +++ b/deploy/nginx.conf @@ -8,6 +8,10 @@ server { root /srv/releases/current; charset utf-8; error_page 404 /404.html; # Astro emits 404.html at the site root + # Directory redirects (/admin -> /admin/) must stay relative: an absolute + # redirect is built from listen port 80 and loses the real port whenever the + # site is reached through a tunnel or a proxy on a non-default port. + absolute_redirect off; # Fingerprinted build assets (/_astro/..*) — immutable location /_astro/ { diff --git a/src/layouts/Base.astro b/src/layouts/Base.astro index 8658bea..6d8dae0 100644 --- a/src/layouts/Base.astro +++ b/src/layouts/Base.astro @@ -169,7 +169,7 @@ const links = [ Site settings {/* Internal tooling stays out of the main nav (NN/g: navigation reflects user tasks); the editor is a discreet utility link for the demo. */} - Content editor + Content editor
{/* The real brand flash — path taken from the official logo SVG (BRAND D.4).