You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Discovered while investigating #104 (k8s console onboarding): traced deploy_provision's call chain (deploy_provision → t_provision → provision_from_library → oabctl::studio_api::redeploy) and found redeploy()requires an already-stored manifest (load_manifest() → S3 GetObject at manifests/{namespace}/{name}.yaml) — it only patches an existing manifest's image/bundle_from, it never creates a manifest's first version.
The only place a manifest's first version gets written to S3 is apply.rs::apply_manifests (called via deploy_apply → apply_deployment), which requires the caller to hand it a complete manifest YAML (networking, resources, secrets, runtime — everything create.rs's CLI wizard collects interactively).
The console's "+ New fleet" wizard (deploy.ts) only ever calls deploy_provision, never deploy_apply. If that's the full picture, the console currently has no way to create a genuinely new agent from scratch — it can only "redeploy" (bump image/bundle) an agent that already has a stored manifest, created some other way (today: the CLI's oabctl create wizard).
This is not k8s-specific — it's true for AWS today too. It surfaced during k8s work because adding a k8s branch to deploy_provision would just inherit the same limitation, so k8s support was blocked on deciding how to fix this properly rather than papering over it.
Decision (2026-08-27, Brett)
Of three options discussed (see #104's comment thread for the AWS-only "make K8sDriver mirror the missing behavior" and "cram creation into redeploy" alternatives, both rejected):
Go with: wire manifest creation through deploy_apply's existing create-or-update path (apply_manifests), not deploy_provision/redeploy.redeploy stays what its name says — patch-and-reapply an existing manifest. Creation is a distinct operation with its own entry point, matching the semantic boundary that already exists in the code (deploy_apply = give me an exact manifest, create-or-update; deploy_provision = compose-from-template convenience wrapper around redeploy).
Scope
Confirm the trace above is right — rule out a manifest-creation path this investigation missed, before building on the finding.
Manifest construction for a first deploy_provision call: compose_named/Bundle (what provision_from_library uses today) only produces files+image_tag, not a full OABServiceManifest (no networking/resources/secrets/runtime). Need either:
the console to collect the missing fields itself (bigger UI lift), or
sensible defaults ported from create.rs's wizard (same defaults an interactive CLI run would produce for a bare template), so console keeps asking only what it asks today (name/image/template) and the rest is filled in.
Orchestration: the console-facing call (still one call, to keep the wizard a single step) needs to branch — no stored manifest yet → build one (via the above) and persist+apply through the same path deploy_apply uses (apply_manifests), not a parallel mechanism; manifest already exists → today's redeploy patch-and-reapply, unchanged.
Context
Discovered while investigating #104 (k8s console onboarding): traced
deploy_provision's call chain (deploy_provision→t_provision→provision_from_library→oabctl::studio_api::redeploy) and foundredeploy()requires an already-stored manifest (load_manifest()→ S3 GetObject atmanifests/{namespace}/{name}.yaml) — it only patches an existing manifest'simage/bundle_from, it never creates a manifest's first version.The only place a manifest's first version gets written to S3 is
apply.rs::apply_manifests(called viadeploy_apply→apply_deployment), which requires the caller to hand it a complete manifest YAML (networking, resources, secrets, runtime — everythingcreate.rs's CLI wizard collects interactively).The console's "+ New fleet" wizard (
deploy.ts) only ever callsdeploy_provision, neverdeploy_apply. If that's the full picture, the console currently has no way to create a genuinely new agent from scratch — it can only "redeploy" (bump image/bundle) an agent that already has a stored manifest, created some other way (today: the CLI'soabctl createwizard).This is not k8s-specific — it's true for AWS today too. It surfaced during k8s work because adding a k8s branch to
deploy_provisionwould just inherit the same limitation, so k8s support was blocked on deciding how to fix this properly rather than papering over it.Decision (2026-08-27, Brett)
Of three options discussed (see #104's comment thread for the AWS-only "make K8sDriver mirror the missing behavior" and "cram creation into redeploy" alternatives, both rejected):
Go with: wire manifest creation through
deploy_apply's existing create-or-update path (apply_manifests), notdeploy_provision/redeploy.redeploystays what its name says — patch-and-reapply an existing manifest. Creation is a distinct operation with its own entry point, matching the semantic boundary that already exists in the code (deploy_apply= give me an exact manifest, create-or-update;deploy_provision= compose-from-template convenience wrapper around redeploy).Scope
deploy_provisioncall:compose_named/Bundle(whatprovision_from_libraryuses today) only producesfiles+image_tag, not a fullOABServiceManifest(no networking/resources/secrets/runtime). Need either:create.rs's wizard (same defaults an interactive CLI run would produce for a bare template), so console keeps asking only what it asks today (name/image/template) and the rest is filled in.deploy_applyuses (apply_manifests), not a parallel mechanism; manifest already exists → today'sredeploypatch-and-reapply, unchanged.deploy_provisionk8s dispatch — once this lands with a clean AWS-side "create" path throughdeploy_apply, adding k8s's provider dispatch happens at that same entry point, notredeploy.Explicit non-goals
K8sDriver::applyalready works standalone, per K8s fleet onboarding — console UX for provider selection ('+ New fleet') #104) — this issue is AWS-path-completion only. K8s dispatch resumes in K8s fleet onboarding — console UX for provider selection ('+ New fleet') #104 once this is done.create.rs's CLI wizard — reusing its defaults, not its interactive flow.