Skip to content

codeforphilly-ng: seal CFP_DATA_RELOAD_SECRET for hot-reload webhook#165

Merged
themightychris merged 1 commit into
mainfrom
add-data-reload-secret
May 19, 2026
Merged

codeforphilly-ng: seal CFP_DATA_RELOAD_SECRET for hot-reload webhook#165
themightychris merged 1 commit into
mainfrom
add-data-reload-secret

Conversation

@themightychris
Copy link
Copy Markdown
Member

Adds the bearer secret the running codeforphilly-ng API expects on POST /api/_internal/reload-data (the hot-reload webhook landed upstream in CodeForPhilly/codeforphilly-ng#70). On push to the data repo's published branch, codeforphilly-data's GH Action will POST to that endpoint with Authorization: Bearer <secret>; the bearer must match the env value materialized from this sealed Secret.

Changes

  • codeforphilly-ng.secrets/codeforphilly-secrets.yaml — re-sealed to add CFP_DATA_RELOAD_SECRET alongside the existing 4 keys (CFP_JWT_SIGNING_KEY, CFP_DATA_REMOTE, GITHUB_OAUTH_CLIENT_ID, GITHUB_OAUTH_CLIENT_SECRET). All previous values preserved.

After merge

  • GitOps projection picks this up automatically; the sealed-secrets controller materializes the updated env Secret into the namespace.
  • I'll restart the codeforphilly deployment once the projection lands so the pod's process picks up the new env var (env vars from envFrom: secretRef aren't hot-reloaded into a running container).
  • I'll mirror the same plaintext into codeforphilly-data's repository secrets so the GH Action's bearer matches.

The codeforphilly-ng API exposes `POST /api/_internal/reload-data`
(CodeForPhilly/codeforphilly-ng#70) for the
`codeforphilly-data` repo's `Notify deployments` GH Action to call on
push to `published`. The bearer secret on both sides must match. This
seals the cluster-side copy; the data-repo-side copy is added as a
GitHub repository secret on `codeforphilly-data`.
@themightychris themightychris requested a review from a team as a code owner May 19, 2026 14:59
@themightychris themightychris merged commit 9f8670f into main May 19, 2026
@themightychris themightychris deleted the add-data-reload-secret branch May 19, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant