fix(chart): default relay_signing_public_key to Nudgebee Cloud relay key - #503
fix(chart): default relay_signing_public_key to Nudgebee Cloud relay key#503RamanKharchee wants to merge 1 commit into
Conversation
The chart already defaults `relay_address: wss://relay.nudgebee.com` and `endpoint: https://collector.nudgebee.com` (the SaaS prod triple) but left `relay_signing_public_key: ''`. With an empty key the agent's relay-signature verifier is disabled, so relay-signed UI mutations fall through to the light-action allowlist and every workload mutation (replace_workload, delete_pod, create_workload, rollout_restart, scale, ...) is rejected with `auth: action "<x>" not in light-action allowlist`. Reads keep working because read primitives are light actions — the classic "reads fine, mutations 401". Any agent installed against Nudgebee Cloud without the in-app install command (manual `helm install`, CI-driven installs) hit this. Pair the key with the already-defaulted relay so a plain install authorizes mutations out of the box. The value is the relay's PUBLIC Ed25519 key (verification only, already served at /api/public/app_config) — same SaaS-default posture as the relay/endpoint URLs. The UI install command still overrides it via --set-string; self-hosted relays override it alongside relay_address (comma-separate during rotation). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
📦 Image Tags Updated |
|
|
1 similar comment
|
|
There was a problem hiding this comment.
Code Review
This pull request bumps the Helm chart version of nudgebee-agent to 0.1.6 and configures a default value for relay_signing_public_key in values.yaml, which corresponds to Nudgebee Cloud's relay key. The documentation comments have also been updated to explain the default key behavior, how to override it, and how to handle key rotation. There are no review comments, so I have no feedback to provide.
Description
The
nudgebee-agentchart already defaults the SaaS prod triple —runner.relay_address: wss://relay.nudgebee.com/registerandrunner.nudgebee.endpoint: https://collector.nudgebee.com— but leftrunner.nudgebee.relay_signing_public_key: ''.With an empty relay key, the agent's relay-signature verifier is disabled (
relaysig.NewVerifier("")→Enabled()==false). The relay signs every k8s request body, but the agent ignores the signature, so relay-signed UI mutations fall through to the light-action allowlist inpkg/auth.Validate. Since mutations are deliberately not light actions, every workload mutation is rejected:(also
delete_pod,create_workload,delete_workload,rollout_restart,replica_rightsizing, …). Reads keep working because read primitives are light actions — the classic "reads fine, mutations 401" symptom.Any agent installed against Nudgebee Cloud without the in-app install command — manual
helm install, CI-driven installs — hits this, because only the UI install command injects the key (--set-string runner.nudgebee.relay_signing_public_key=...from the server'sSIGNING_PUBLIC_KEY).Fix
Pair the key with the already-defaulted relay: default
relay_signing_public_keyto Nudgebee Cloud's relay public Ed25519 key, so a plainhelm installagainst Cloud authorizes mutations out of the box./api/public/app_config, and cross-verified against the prod cluster'snudgebeesecretSIGNING_PUBLIC_KEY.--set-string.relay_address(the comment now says so); comma-separate multiple keys during a rotation.Chart version bumped 0.1.5 → 0.1.6 (RC releases derive their tag from
Chart.yamlversion).Type of change
How Has This Been Tested?
iteration-prodagent (and the trackednudgebee-prod-agent): both connect towss://relay.nudgebee.comwith noRELAY_SIGNING_PUBLIC_KEYenv → reproduces the rejection.SIGNING_PRIVATE_KEYpresent, recent image) and the public key matches/api/public/app_config.helm lintpasses (only the expected missing-subchart-dependency warning)._helpers.tplguard{{- if .Values.runner.nudgebee.relay_signing_public_key }}now renders theRELAY_SIGNING_PUBLIC_KEYenv (empty default previously skipped it — matching the broken live state).Review Notes → Risks & Counterarguments
/api/public/app_config, and consistent with the chart's existingrelay.nudgebee.com/collector.nudgebee.comdefaults.Rollout note (not in this PR)
iteration-prodandnudgebee-prod-agentpin chart versions, so they won't pick up the new default until upgraded. Immediate unblock for a pinned release:🤖 Generated with Claude Code