diff --git a/compose.yml b/compose.yml index 12f43ee..2d0feaa 100644 --- a/compose.yml +++ b/compose.yml @@ -227,6 +227,8 @@ services: sed -i 's|`/fonts/|`'"$${SUBPATH}"'fonts/|g' "$$f" sed -i "s|\"/assets/|\"$${SUBPATH}assets/|g" "$$f" sed -i 's|`/assets/|`'"$${SUBPATH}"'assets/|g' "$$f" + sed -i "s|location\.href=\"/\"|location.href=\"$$SUBPATH\"|g" "$$f" + sed -i "s|document\.location\.href=\"/\"|document.location.href=\"$$SUBPATH\"|g" "$$f" echo "[grampsweb] patched JS paths: $$f" fi done diff --git a/deploy-production/docker-compose.prod.yml b/deploy-production/docker-compose.prod.yml index 8eb9688..6e86154 100644 --- a/deploy-production/docker-compose.prod.yml +++ b/deploy-production/docker-compose.prod.yml @@ -153,6 +153,8 @@ services: sed -i 's|`/fonts/|`'"$${SUBPATH}"'fonts/|g' "$$f" sed -i "s|\"/assets/|\"$${SUBPATH}assets/|g" "$$f" sed -i 's|`/assets/|`'"$${SUBPATH}"'assets/|g' "$$f" + sed -i "s|location\.href=\"/\"|location.href=\"$$SUBPATH\"|g" "$$f" + sed -i "s|document\.location\.href=\"/\"|document.location.href=\"$$SUBPATH\"|g" "$$f" echo "[grampsweb] patched JS paths: $$f" fi done