feat(operator): oabctl Phase 1 — apply, get, delete#851
Conversation
Implements the CLI provisioner from ADR docs/adr/ecs-control-plane.md: - oabctl apply -f <file|dir>: validate manifest, render config to S3, register task def, create/update ECS service - oabctl get oabservice: list services via ECS DescribeServices - oabctl delete oabservice <name>: teardown ECS service + S3 cleanup - entrypoint.sh: wrapper script for ECS tasks (bootstrap + config download) Schema: oab.dev/v1 OABService with capacityProvider, cpu, memory, bootstrapFrom, networking, config, secrets fields.
|
All PRs must reference a prior Discord discussion to ensure community alignment before implementation. Please edit the PR description to include a link like: This PR will be automatically closed in 3 days if the link is not added. |
OpenAB PR ScreeningThis is auto-generated by the OpenAB project-screening flow for context collection and reviewer handoff.
Screening reportscreening posted and project item moved to `PR-Screening`.GitHub comment: #851 (comment) IntentPR #851 is trying to add the first usable FeatFeature work. It adds an Who It ServesPrimary beneficiary: deployers and agent runtime operators. Secondary beneficiaries are maintainers, because this creates a concrete Phase 1 control-plane surface that reviewers can harden incrementally. Rewritten PromptImplement Phase 1 of the OpenAB ECS operator as a Rust CLI under
Keep Phase 1 scoped to pre-created SSM bot tokens, one namespace, one AWS region, Discord channel services only, and immutable config artifacts. Include validation errors, predictable resource naming, least-surprise AWS failure handling, and CI that builds/checks the operator crate. Merge PitchThis should move forward because it turns the accepted ECS control-plane ADR into an executable slice with clear maintainer review boundaries: manifest shape, AWS provisioning behavior, teardown semantics, and CI integration. The risk profile is medium-high because it touches real cloud resource creation/deletion, credential references, generated config, and lifecycle cleanup. The likely reviewer concern is not whether the CLI shape is useful; it is whether Best-Practice ComparisonOpenClaw is relevant as a control-plane comparison. This PR aligns with explicit delivery/provisioning intent and isolated ECS executions, but reviewers should check for durable job/state tracking, retry/backoff, and run logs. Phase 1 appears artifact-driven through S3 generations, which is good, but AWS mutations still need clear ownership tags and recovery behavior. Hermes Agent is partially relevant. Its atomic persisted state and self-contained scheduled prompts map to the same reliability concerns: generated state should be persisted atomically, each provisioned service should be reconstructable from manifest plus generation artifact, and repeated runs should be safe. The gateway daemon tick model is less applicable here because this is an operator CLI, not a scheduler. Implementation OptionsConservative: merge only the manifest schema, CLI skeleton, validation, Balanced: merge this Phase 1 as a complete experimental operator behind explicit docs and strong constraints, after focused review of idempotency, ownership tags, S3 key layout, ECS update behavior, and delete safety. Add targeted unit tests for manifest validation and command planning, plus a dry-run or plan-style path if feasible. Ambitious: expand the PR into a more production-grade controller surface before merge: persisted operation records, structured run logs, retry/backoff, lock/lease protection, explicit rollback handling, and integration tests against localstack or a dedicated AWS test environment. Comparison Table
RecommendationTake the balanced path. Keep the PR scoped as Phase 1, but require focused review on AWS mutation safety before merge: idempotent |
Summary
Implements
oabctlCLI provisioner underoperator/as defined in the merged ADR (docs/adr/ecs-control-plane.md).What's included
oabctl apply -f <file|dir>— validate manifest, render config.toml to S3 (immutable path per generation), register ECS task definition, create/update ECS serviceoabctl get oabservice [name]— real-time ECS DescribeServices, displays status tableoabctl delete oabservice <name>— scale to 0, delete service, cleanup S3 manifests/configentrypoint.sh— ECS task wrapper: restore bootstrap → overwrite with rendered config → start OABoab.dev/v1 OABServicewith validationProject structure
Build
Phase 1 scope (per ADR)
cc @pahud