feat(branding): implement dynamic branding in service worker and reports (#383)

* feat(branding): implement dynamic branding in service worker and reports

* refactor(service-worker): remove push notification handling code

* feat(service-worker): implement dynamic branding in service worker and related scripts
This commit is contained in:
Mattsson
2026-04-30 17:17:41 +02:00
committed by GitHub
parent c86dbdc60d
commit 5e1b0f791d
11 changed files with 81 additions and 9 deletions
+9
View File
@@ -40,4 +40,13 @@ if [ -d /app/.next/static ]; then
{} +
fi
# Stamp the service worker fallback notification title with the brand name.
# public/sw.js is served as a static file (not bundled by Next), so NEXT_PUBLIC_*
# inlining doesn't reach it — substitute the placeholder here at container start.
if [ -f /app/public/sw.js ]; then
sed -i \
-e "s|__NEXT_PUBLIC_BRANDING_APP_NAME__|${NEXT_PUBLIC_BRANDING_APP_NAME:-Gnubok}|g" \
/app/public/sw.js
fi
exec "$@"