From 755ede6cdae8570037a7cf59218f2baebbcdd631 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Tue, 27 Jan 2026 21:47:57 +0200 Subject: fix: serve f3s fallback page when cluster is down - Add explicit httpd server blocks for f3s.buetow.org and *.f3s.buetow.org on port 8080 - These blocks serve /htdocs/f3s_fallback with request rewrite to /index.html - Prevents httpd from falling back to blowfish.buetow.org's directory autoindex - Now correctly shows fallback page for all f3s hosts when k3s cluster is unreachable Amp-Thread-ID: https://ampcode.com/threads/T-019c00f6-c61d-772a-8fe2-dc0aee0a4ce2 Co-authored-by: Amp --- frontends/etc/httpd.conf.tpl | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/frontends/etc/httpd.conf.tpl b/frontends/etc/httpd.conf.tpl index 24889d5..5f4a769 100644 --- a/frontends/etc/httpd.conf.tpl +++ b/frontends/etc/httpd.conf.tpl @@ -39,6 +39,29 @@ server "<%= "$hostname.$domain" %>" { } } +# f3s cluster fallback page on port 8080 when cluster is down +server "f3s.buetow.org" { + listen on * port 8080 + log style forwarded + location * { + # Rewrite all requests to /index.html to show fallback page regardless of path + request rewrite "/index.html" + root "/htdocs/f3s_fallback" + } +} + +# Catch-all for any unmatched .f3s.buetow.org subdomain on port 8080 +# Serves fallback page when k3s cluster is down +server "*.f3s.buetow.org" { + listen on * port 8080 + log style forwarded + location * { + # Rewrite all requests to /index.html to show fallback page regardless of path + request rewrite "/index.html" + root "/htdocs/f3s_fallback" + } +} + # Gemtexter hosts <% for my $host (qw/foo.zone stats.foo.zone/) { for my $prefix (@prefixes) { -%> server "<%= $prefix.$host %>" { -- cgit v1.2.3