container-runtime-policies hands config.ContainerConfig to the wire, so its keys are Go field names #1536

Closed
opened 2026-10-27 13:40:47 +00:00 by sam · 0 comments
Owner

operational_settings.go defines the container-runtime-policies resource with Document: config.ContainerConfig{}, a TOML struct with no json tags. encoding/json falls back to Go field names, so the stored document and the Web UI contract are Image, MaxConcurrency, MaxUptime, VolumeTTL, PullPolicy, Network, Profiles{Image, Tools} rather than snake_case. internal/infrastructure/controlplanerpc/vocabulary.go records the same defect for channel-settings and the fix used there: a document type owned by the contract with explicit snake_case tags, whose UnmarshalJSON also reads the Go-cased keys already stored. Do the same for container runtime policies, and update ui/src/settings/ContainerRuntimePage.vue in the same change.

Acceptance criteria

The resource document has snake_case keys; documents stored with Go-cased keys still decode; the container runtime page reads the new keys.

Close reason

Delivered and pinned; verified against HEAD this session (#1171 via internal/app/controlplane/container_settings.go, #1174 via internal/app/archied/sd_notify.go call sites). Container tests ok 1.828s; archied notify tests ok 5.880s.


Imported from beads archie-core-qna6 · GitHub #1060 · type bug · priority P2 · created 2026-09-25 · closed 2026-09-30

operational_settings.go defines the container-runtime-policies resource with Document: config.ContainerConfig{}, a TOML struct with no json tags. encoding/json falls back to Go field names, so the stored document and the Web UI contract are Image, MaxConcurrency, MaxUptime, VolumeTTL, PullPolicy, Network, Profiles{Image, Tools} rather than snake_case. internal/infrastructure/controlplanerpc/vocabulary.go records the same defect for channel-settings and the fix used there: a document type owned by the contract with explicit snake_case tags, whose UnmarshalJSON also reads the Go-cased keys already stored. Do the same for container runtime policies, and update ui/src/settings/ContainerRuntimePage.vue in the same change. ### Acceptance criteria The resource document has snake_case keys; documents stored with Go-cased keys still decode; the container runtime page reads the new keys. ### Close reason Delivered and pinned; verified against HEAD this session (#1171 via internal/app/controlplane/container_settings.go, #1174 via internal/app/archied/sd_notify.go call sites). Container tests ok 1.828s; archied notify tests ok 5.880s. --- _Imported from beads `archie-core-qna6` · GitHub #1060 · type bug · priority P2 · created 2026-09-25 · closed 2026-09-30_
sam added the mediumbug labels 2026-10-27 13:40:47 +00:00
sam self-assigned this 2026-10-27 13:40:47 +00:00
sam closed this issue 2026-10-27 13:40:47 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sam/archie#1536