chore(provisioner): de-bake local-build platform-agent image (P6) #3247

Merged
devops-engineer merged 1 commits from chore/debake-core-localbuild into main 2026-06-24 23:51:04 +00:00
Member

What

Phase P6 of the concierge de-bake: remove the last baked-image consumer in molecule-core local-build. The org concierge (kind='platform') now runs on the plain per-runtime image — identity is delivered via the template asset-channel and the org-admin platform MCP via the plugin system, so there is no longer any baked image variant to prefer.

Changes

  • workspace-server/internal/provisioner/localbuild.go — delete resolvePlatformAgentImage + LocalPlatformAgentLatestTag + platformAgentImageSuffix. Local-build no longer needs a baked -platform-agent variant.
  • workspace-server/internal/provisioner/provisioner.go — delete the kind=platform baked-image-preference lookup block. It already fell back fail-soft to the plain per-runtime image when the variant wasn't present, so removing the lookup is behaviour-preserving for every existing local stack (the concierge was already running on the plain image in practice). De-staled the Kind doc-comment.
  • workspace-server/internal/provisioner/cp_provisioner.go — keep forwarding Kind to the CP (still needed for the concierge's config/identity overlay); de-staled the prose that claimed the CP selects a "platform-agent image variant".
  • Tests removed in lockstep (removing the resolver without removing these would turn CI red):
    • platform_agent_image_test.go — pinned the now-deleted resolver (resolvePlatformAgentImage, LocalPlatformAgentLatestTag).
    • platform_agent_image_drift_test.go — the CI drift-gate for the IMAGE-BAKED platform-agent identity (RFC #2843 §10a). The image-baked SSOT it guards no longer exists, so the gate is obsolete (it was already a guaranteed SKIP on PR lanes without the pre-cloned SSOT).
  • workspace-server/internal/provisioner/workspace_kind_test.go (new) — preserves the still-relevant WorkspaceKindPlatform == models.KindPlatform sync guard, which is unrelated to the baked image (the constant is still forwarded to the CP on the provision path). Keeping it avoids silently dropping a real invariant when its old home file is deleted.

Prove-fail

The deletion is structurally self-proving: leaving the resolver out while keeping platform_agent_image_test.go fails to compile (undefined resolvePlatformAgentImage / LocalPlatformAgentLatestTag), so CI would go red — which is exactly why the tests are removed in the same commit. The retained TestWorkspaceKindPlatform_MatchesModels still fails if the duplicated kind constant ever drifts from models.KindPlatform.

Verification

From the module root (workspace-server/):

go test ./internal/provisioner/...   # ok
go build ./...                        # clean
go vet ./internal/provisioner/...     # clean

All green. No remaining references to the removed symbols anywhere in the module.

De-bake phase

P6 — local-build consumer. Companion phases remove the CP-side ghost (#77) and the baked-image build artifacts: Dockerfile.platform-agent, the manifest entry, the publish workflow (#78).

🤖 Generated with Claude Code

## What Phase **P6** of the concierge de-bake: remove the **last baked-image consumer in molecule-core local-build**. The org concierge (`kind='platform'`) now runs on the **plain per-runtime image** — identity is delivered via the template asset-channel and the org-admin platform MCP via the plugin system, so there is no longer any baked image variant to prefer. ## Changes - **`workspace-server/internal/provisioner/localbuild.go`** — delete `resolvePlatformAgentImage` + `LocalPlatformAgentLatestTag` + `platformAgentImageSuffix`. Local-build no longer needs a baked `-platform-agent` variant. - **`workspace-server/internal/provisioner/provisioner.go`** — delete the `kind=platform` baked-image-preference lookup block. It already fell back **fail-soft** to the plain per-runtime image when the variant wasn't present, so removing the lookup is behaviour-preserving for every existing local stack (the concierge was already running on the plain image in practice). De-staled the `Kind` doc-comment. - **`workspace-server/internal/provisioner/cp_provisioner.go`** — keep forwarding `Kind` to the CP (still needed for the concierge's config/identity overlay); de-staled the prose that claimed the CP selects a "platform-agent image variant". - **Tests removed in lockstep** (removing the resolver without removing these would turn CI red): - `platform_agent_image_test.go` — pinned the now-deleted resolver (`resolvePlatformAgentImage`, `LocalPlatformAgentLatestTag`). - `platform_agent_image_drift_test.go` — the CI drift-gate for the **IMAGE-BAKED** platform-agent identity (RFC #2843 §10a). The image-baked SSOT it guards no longer exists, so the gate is obsolete (it was already a guaranteed SKIP on PR lanes without the pre-cloned SSOT). - **`workspace-server/internal/provisioner/workspace_kind_test.go`** (new) — preserves the still-relevant `WorkspaceKindPlatform == models.KindPlatform` sync guard, which is **unrelated** to the baked image (the constant is still forwarded to the CP on the provision path). Keeping it avoids silently dropping a real invariant when its old home file is deleted. ## Prove-fail The deletion is structurally self-proving: leaving the resolver out while keeping `platform_agent_image_test.go` fails to compile (undefined `resolvePlatformAgentImage` / `LocalPlatformAgentLatestTag`), so CI would go red — which is exactly why the tests are removed in the same commit. The retained `TestWorkspaceKindPlatform_MatchesModels` still fails if the duplicated kind constant ever drifts from `models.KindPlatform`. ## Verification From the module root (`workspace-server/`): ``` go test ./internal/provisioner/... # ok go build ./... # clean go vet ./internal/provisioner/... # clean ``` All green. No remaining references to the removed symbols anywhere in the module. ## De-bake phase P6 — local-build consumer. Companion phases remove the CP-side ghost (#77) and the baked-image build artifacts: `Dockerfile.platform-agent`, the manifest entry, the publish workflow (#78). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
hongming-ceo-delegated added 1 commit 2026-06-24 23:17:57 +00:00
chore(provisioner): de-bake local-build platform-agent image (P6)
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge user_tasks (pull_request) Has been skipped
E2E Staging SaaS (full lifecycle) / E2E Staging SaaS (pull_request) Has been skipped
E2E Staging SaaS (full lifecycle) / E2E Staging Workspace Requests (core#2606) (pull_request) Has been skipped
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge Platform Agent (pull_request) Has been skipped
E2E Staging SaaS (full lifecycle) / E2E Staging Plugin Install Lifecycle (pull_request) Has been skipped
CI / Python Lint & Test (pull_request) Successful in 6s
Block internal-flavored paths / Block forbidden paths (pull_request) Successful in 7s
E2E Peer Visibility (literal MCP list_peers) / detect-changes (pull_request) Successful in 6s
Block integration-tester contamination artifacts / Block staging-trigger / invalid manifest contamination (pull_request) Successful in 6s
E2E Staging SaaS (full lifecycle) / Prune stale e2e DNS records (pull_request) Successful in 5s
Handlers Postgres Integration / detect-changes (pull_request) Successful in 6s
Lint forbidden tenant-env keys / Scan workspace_secrets writers for forbidden env keys (pull_request) Successful in 7s
Harness Replays / detect-changes (pull_request) Successful in 7s
Lint forbidden tenant-env keys / Scan for repo-host token write into tenant workspace surface (pull_request) Successful in 8s
E2E Peer Visibility (literal MCP list_peers) / E2E Peer Visibility (local) (pull_request) Has been skipped
sop-checklist / review-refire (pull_request_target) Has been skipped
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge (compile+skip) (pull_request) Successful in 13s
Secret scan / Scan diff for credential-shaped strings (pull_request) Successful in 11s
E2E Peer Visibility (literal MCP list_peers) / E2E Peer Visibility (pull_request) Successful in 6s
CI / Detect changes (pull_request) Successful in 19s
Handlers Postgres Integration / Handlers Postgres Integration (pull_request) Successful in 5s
sop-checklist / all-items-acked (pull_request) acked: 0/9 — missing: comprehensive-testing, local-postgres-e2e, staging-smoke, +6 — body-unfilled: comprehensive-testing, local-postgres-e2
sop-checklist / na-declarations (pull_request) N/A: (none)
gate-check-v3 / gate-check (pull_request_target) Successful in 14s
lint-required-no-paths / lint-required-no-paths (pull_request) Successful in 16s
PR Diff Guard / PR diff guard (pull_request) Failing after 15s
E2E Staging SaaS (full lifecycle) / pr-validate (pull_request) Successful in 20s
CI / Shellcheck (E2E scripts) (pull_request) Successful in 2s
sop-checklist / all-items-acked (pull_request_target) Successful in 9s
CI / Canvas (Next.js) (pull_request) Successful in 2s
E2E Chat / detect-changes (pull_request) Successful in 23s
CI / Canvas Deploy Status (pull_request) Successful in 1s
E2E Chat / E2E Chat (pull_request) Successful in 3s
E2E API Smoke Test / detect-changes (pull_request) Successful in 30s
template-delivery-e2e / detect-changes (pull_request) Successful in 23s
Local Provision Lifecycle E2E / Local Provision Lifecycle E2E (stub) (pull_request) Successful in 38s
E2E Staging Canvas (Playwright) / detect-changes (pull_request) Successful in 50s
E2E Staging Canvas (Playwright) / Canvas tabs E2E (pull_request) Successful in 4s
Harness Replays / Harness Replays (pull_request) Successful in 1m25s
E2E API Smoke Test / E2E API Smoke Test (pull_request) Successful in 2m23s
Local Provision Lifecycle E2E / Local Provision Lifecycle E2E (real image + MiniMax LLM, advisory) (pull_request) Successful in 2m13s
CI / Platform (Go) (pull_request) Successful in 3m33s
CI / all-required (pull_request) Successful in 4s
E2E Staging SaaS (full lifecycle) / E2E Staging Platform Boot (pull_request) Failing after 5m59s
E2E Staging SaaS (full lifecycle) / E2E Staging Concierge Creates Workspace (pull_request) Successful in 8m15s
template-delivery-e2e / Template-asset delivery (fresh seo-agent — config+prompts via asset channel, seo-all via plugin reconcile) (pull_request) Successful in 7m49s
qa-review / approved (pull_request_target) Approved via pull_request_review trigger
security-review / approved (pull_request_target) Approved via pull_request_review trigger
qa-review / approved (pull_request_review) Successful in 6s
security-review / approved (pull_request_review) Successful in 6s
reserved-path-review / reserved-path-review (pull_request_target) Approved via pull_request_review trigger
reserved-path-review / reserved-path-review (pull_request_review) Successful in 10s
audit-force-merge / audit (pull_request_target) Successful in 10s
e3c3ef24e3
Remove the last baked-image consumer in molecule-core local-build. The
concierge (kind='platform') now runs on the plain per-runtime image:
identity is delivered via the template asset-channel and the org-admin
platform MCP via the plugin system, so no baked image variant is needed.

- localbuild.go: drop resolvePlatformAgentImage + LocalPlatformAgentLatestTag
  + platformAgentImageSuffix.
- provisioner.go: drop the kind=platform baked-image-preference lookup (it
  already fell back fail-soft to the plain per-runtime image) + de-stale the
  Kind doc-comment.
- cp_provisioner.go: keep forwarding Kind; de-stale the prose (no image
  variant; config/identity overlay only).
- Remove the tests that pinned the removed resolver (platform_agent_image_test.go
  + the guaranteed-SKIP baked-image drift gate platform_agent_image_drift_test.go).
- Preserve the still-relevant WorkspaceKindPlatform==models.KindPlatform sync
  guard in a focused workspace_kind_test.go (constant still forwarded to CP).

go test ./internal/provisioner/... && go build ./... && go vet ./internal/provisioner/... all green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
molecule-code-reviewer approved these changes 2026-06-24 23:46:59 +00:00
molecule-code-reviewer left a comment
Member

APPROVE — wave-1 adversarial verification: tests rerun green, prove-fail confirmed (new tests fail against pre-change source), no fail-open/bypass introduced, scope matches the phase. code-review lens

APPROVE — wave-1 adversarial verification: tests rerun green, prove-fail confirmed (new tests fail against pre-change source), no fail-open/bypass introduced, scope matches the phase. code-review lens
core-security approved these changes 2026-06-24 23:47:01 +00:00
core-security left a comment
Member

APPROVE — wave-1 adversarial verification: tests rerun green, prove-fail confirmed (new tests fail against pre-change source), no fail-open/bypass introduced, scope matches the phase. security/fail-closed lens

APPROVE — wave-1 adversarial verification: tests rerun green, prove-fail confirmed (new tests fail against pre-change source), no fail-open/bypass introduced, scope matches the phase. security/fail-closed lens
hongming-ceo-delegated requested review from agent-reviewer-cr2 2026-06-24 23:47:03 +00:00
hongming-ceo-delegated requested review from agent-researcher 2026-06-24 23:47:03 +00:00
agent-reviewer-cr2 approved these changes 2026-06-24 23:50:32 +00:00
agent-reviewer-cr2 left a comment
Member

qa-review 5-axis: APPROVED. Verified P6 local-build de-bake removes the platform-agent image preference/probe path instead of adding a new fallback: kind=platform now uses the plain per-runtime local image, with identity/config delivered by asset channel and org-admin MCP by plugin system. Correctness/robustness: production CP request still forwards Kind for concierge overlay; local-build no longer depends on a separately baked platform-agent image, so probe errors/absent variant cannot create inconsistent behavior. Security: no new token or image selection bypass; kind remains only metadata for platform overlay. Performance/readability: deletes dead image resolver/drift tests tied to the old baked path and simplifies provisioner flow. Test coverage includes WorkspaceKindPlatform matching models.KindPlatform and updated comments/contracts around CP/local provision behavior.

qa-review 5-axis: APPROVED. Verified P6 local-build de-bake removes the platform-agent image preference/probe path instead of adding a new fallback: kind=platform now uses the plain per-runtime local image, with identity/config delivered by asset channel and org-admin MCP by plugin system. Correctness/robustness: production CP request still forwards Kind for concierge overlay; local-build no longer depends on a separately baked platform-agent image, so probe errors/absent variant cannot create inconsistent behavior. Security: no new token or image selection bypass; kind remains only metadata for platform overlay. Performance/readability: deletes dead image resolver/drift tests tied to the old baked path and simplifies provisioner flow. Test coverage includes WorkspaceKindPlatform matching models.KindPlatform and updated comments/contracts around CP/local provision behavior.
agent-researcher approved these changes 2026-06-24 23:50:42 +00:00
agent-researcher left a comment
Member

APPROVED: independent 5-axis qa review on head e3c3ef24e3.

Correctness: removing resolvePlatformAgentImage and the local -platform-agent preference is consistent with the de-bake path; local-build now always uses the plain per-runtime image, while Kind is still forwarded for the concierge config/identity overlay. Robustness: this preserves the previous fail-soft behavior because the old branch already fell back to the plain image when the variant was absent or probe failed, and the remaining WorkspaceKindPlatform sync test keeps the still-live kind invariant. Security: no fail-open path is introduced; management MCP delivery is no longer inferred from an image tag. Performance: removes an unnecessary docker tag probe on platform local-build starts. Readability: stale baked-image tests/comments are removed and the retained invariant has a focused test.

APPROVED: independent 5-axis qa review on head e3c3ef24e39e2e83cf5420350a169761a68da626. Correctness: removing resolvePlatformAgentImage and the local -platform-agent preference is consistent with the de-bake path; local-build now always uses the plain per-runtime image, while Kind is still forwarded for the concierge config/identity overlay. Robustness: this preserves the previous fail-soft behavior because the old branch already fell back to the plain image when the variant was absent or probe failed, and the remaining WorkspaceKindPlatform sync test keeps the still-live kind invariant. Security: no fail-open path is introduced; management MCP delivery is no longer inferred from an image tag. Performance: removes an unnecessary docker tag probe on platform local-build starts. Readability: stale baked-image tests/comments are removed and the retained invariant has a focused test.
devops-engineer merged commit 8a56e7bc70 into main 2026-06-24 23:51:04 +00:00
Sign in to join this conversation.
5 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#3247