trails/.github/workflows
Ullrich Schäfer edb618fe40
fix(sentry): remove hardcoded DSN fallbacks; supply via env in CI
Self-hosted instances no longer inherit the trails.cool flagship Sentry
DSNs. Code paths now read DSN strictly from env — unset = no Sentry
init, no events sent.

Flagship continues to report unchanged: cd-apps.yml and cd-staging.yml
inject the public DSNs as workflow env vars, which feed into:
- runtime via \`infrastructure/app.env\` / \`staging.env\`
  (\`SENTRY_DSN_JOURNAL\` / \`SENTRY_DSN_PLANNER\` → compose env per service)
- build time via docker build-arg \`VITE_SENTRY_DSN\` (journal only;
  planner has no client Sentry init).

Sentry DSNs are public-by-design (transmitted unencrypted from the
client JS bundle), so embedding them as plaintext workflow env vars
is no worse than the runtime exposure. Forks should replace these with
their own DSNs or remove the workflow env lines to ship Sentry-free.

Files changed:
- apps/journal/server.ts: \`process.env.SENTRY_DSN\` only, no fallback
- apps/planner/server.ts: same
- apps/journal/app/lib/sentry.client.ts: \`import.meta.env.VITE_SENTRY_DSN\`
  only; falsy = skip init
- apps/journal/Dockerfile: new \`ARG VITE_SENTRY_DSN\` baked into build
- infrastructure/docker-compose.yml: pass \`SENTRY_DSN\` per service
- infrastructure/docker-compose.staging.yml: same
- .github/workflows/cd-apps.yml: workflow env + build-arg + app.env echo
- .github/workflows/cd-staging.yml: same

Full repo: pnpm typecheck, pnpm lint, pnpm test, journal build all green.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-25 23:07:07 +02:00
..
cd-apps.yml fix(sentry): remove hardcoded DSN fallbacks; supply via env in CI 2026-05-25 23:07:07 +02:00
cd-brouter.yml Update brouter deploy scp to single ssh 2026-04-24 14:41:30 +02:00
cd-infra.yml Rebuild the Journal home around a public feed and flagship marketing 2026-04-24 20:00:23 +02:00
cd-staging.yml fix(sentry): remove hardcoded DSN fallbacks; supply via env in CI 2026-05-25 23:07:07 +02:00
ci.yml fix: add E2E opt-out for fail-loud secret/DB-URL guards 2026-05-24 11:45:09 +02:00
dependabot-dedupe.yml Prefix dedupe commit message + set GH_TOKEN for push step 2026-04-19 21:06:38 +02:00
staging-cleanup.yml Fix concurrent preview deploy race: per-PR env files + server flock 2026-05-10 13:03:52 +02:00
update-visual-snapshots.yml Bump stefanzweifel/git-auto-commit-action from 5 to 7 2026-05-17 08:22:36 +00:00