fix(staging): generated staging secrets get a valid ALERTMANAGER_NTFY_TOPIC #271
Loading…
Reference in a new issue
No description provided.
Delete branch "jfraeys/fix/staging-ntfy-topic"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
staging-validate on
4460c44(run 1003) failed in the services deploy at `alertmanager : Fail if the ntfy topic is unsafe to use in a URL or too guessable`. Regenerating `secrets/staging.sops.yml` for the key rename (#269) was the first time `ALERTMANAGER_NTFY_TOPIC` appeared in the staging file, and `gen-staging-secrets.py` gave it the catch-all `staging-unused` (14 chars); the role requires 16-64 characters of `A-Za-z0-9_-`.Fix: the generator returns `staging-` + 24 random hex characters for that key (valid, random, so nobody subscribes to it). Test: `scripts/tests/test_gen_staging_secrets.py`, in lint; it also asserts the role still has the rule it assumes.
Needs the operator before merge (the staging file on main is the broken one):
I checked the other format rules in the roles (`grep 'is match('`): only this one applies to a vault-sourced value that staging exercises. Later tasks in the services play have not run yet in this failure, so another surprise is possible.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Ge5tovcwdEUBtPwUktsZZZ