From 8d0ad57d7b89d4ad6e4112075d7c48ffd159d78f Mon Sep 17 00:00:00 2001 From: Jim Winstead Date: Mon, 23 Sep 2024 15:13:19 -0700 Subject: [PATCH] Fix the Caddyfile for Docker to include rewrite rules (#3246) * Fix stray PHP closing tag in template * Add rewrites for JS/CSS --- docker/caddy/Caddyfile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docker/caddy/Caddyfile b/docker/caddy/Caddyfile index b521d9cd4..c29d4bec0 100644 --- a/docker/caddy/Caddyfile +++ b/docker/caddy/Caddyfile @@ -5,6 +5,13 @@ # our root is in /srv root * /app + # Rewrites + rewrite /js/canary.js /js/known.min.js + @css path_regexp css ^/css/[0-9]+/(.*)$ + rewrite @css /css/{re.css.1} + @js path_regexp js ^/js/[0-9]+/(.*)$ + rewrite @js /js/{re.js.1} + # pass everything else to php php_fastcgi known:9000 { env HTTPS on