diff --git a/config/services/chir-rs.nix b/config/services/chir-rs.nix index 3ca2aa0e..e3a59c55 100644 --- a/config/services/chir-rs.nix +++ b/config/services/chir-rs.nix @@ -13,9 +13,9 @@ useACMEHost = "chir.rs"; extraConfig = '' import baseConfig + rewrite * /api.chir.rs/{path} reverse_proxy { to http://localhost:8621 - rewrite * /api.chir.rs/{path} } ''; }; diff --git a/config/services/old-homepage.nix b/config/services/old-homepage.nix index 8db9415a..aa03ff9e 100644 --- a/config/services/old-homepage.nix +++ b/config/services/old-homepage.nix @@ -31,9 +31,10 @@ in { extraConfig = '' import baseConfig + rewrite * /file/darkkirb-de/{path} + reverse_proxy { to https://f000.backblazeb2.com - rewrite * /file/darkkirb-de/{path} header_up Host {upstream_hostport} transport http { diff --git a/config/services/reverse-proxy.nix b/config/services/reverse-proxy.nix index f90fec8a..6c6ddba7 100644 --- a/config/services/reverse-proxy.nix +++ b/config/services/reverse-proxy.nix @@ -9,12 +9,12 @@ useACMEHost = "chir.rs"; extraConfig = '' import baseConfig + ${extra} + reverse_proxy { to ${dest} header_up Host {upstream_hostport} - ${extra} - transport http { versions 1.1 2 3 } @@ -51,6 +51,8 @@ in { @getOnly { method GET } + rewrite * /file/mastodon-chir-rs/{path} + reverse_proxy @getOnly { to https://f000.backblazeb2.com header_up Host {upstream_hostport} @@ -60,7 +62,6 @@ in { header_down -Access-Control-Allow-Methods header_down Access-Control-Allow-Headers header_up -Set-Cookie - rewrite * /file/mastodon-chir-rs/{path} transport http { versions 1.1 2 3