fix(netbird-rotation): use python:alpine — apk install fails under non-root PSA #307

Merged
k.renner merged 1 commits from fix/class-b-rotation-image into master 2026-07-19 06:48:44 +00:00
Member

Bug found while testing #304: the job failed at apk add curl jq — "Unable to lock database: Permission denied". It runs non-root (runAsUser 65534) and the openbao ns enforces restricted PSA, so apk/apt (need root) can't install anything. The influxdb precedent only worked because it ran as root.

Fix: switch to python:3.13-alpine and do OpenBao login + API call + KV patch via Python stdlib (urllib/json) — no runtime install, runs cleanly non-root. Verified: kustomize + python syntax clean.

The same fix is needed on the still-open #305 (cloudflare) and #306 (proxmox) — I'll push it to those branches too.

**Bug found while testing #304**: the job failed at `apk add curl jq` — *"Unable to lock database: Permission denied"*. It runs non-root (`runAsUser 65534`) and the openbao ns enforces restricted PSA, so `apk`/`apt` (need root) can't install anything. The influxdb precedent only worked because it ran as root. **Fix**: switch to `python:3.13-alpine` and do OpenBao login + API call + KV patch via Python stdlib (`urllib`/`json`) — no runtime install, runs cleanly non-root. Verified: kustomize + python syntax clean. The same fix is needed on the still-open **#305 (cloudflare)** and **#306 (proxmox)** — I'll push it to those branches too.
claude-bot added 1 commit 2026-07-19 06:45:15 +00:00
Testing #304 revealed the runtime 'apk add curl jq' fails ('Unable to lock database: Permission denied') because the job runs non-root (runAsUser 65534) and the openbao ns enforces restricted PSA — apk needs root. Switch to python:3.13-alpine and do the HTTP/JSON via stdlib (urllib/json), no package install, non-root-safe. Same fix must be applied to the still-open cloudflare (#305) and proxmox (#306) Class-B jobs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015K7gLUVVnutvDnzV2TrMRJ
k.renner merged commit 30561a62a3 into master 2026-07-19 06:48:44 +00:00
Sign in to join this conversation.