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
feat: ReaperPod CRD, reaper-controller, and Helm chart (#31)
* feat(controller): add ReaperPod CRD and reaper-controller binary
Introduce a ReaperPod custom resource that provides a simplified,
Reaper-native way to run workloads. A new reaper-controller binary
watches ReaperPod resources and creates real Pods with runtimeClassName
pre-configured, translating the simplified spec (inline volumes,
dnsMode, overlayName) into full Pod specs with owner references.
- CRD types with own simple structs (avoids k8s-openapi schemars dep)
- Pod builder with 9 unit tests covering all field translations
- Reconciler using kube::runtime::Controller with owns() for Pod watches
- Deployment manifests, Dockerfile, build/generate scripts
- Example YAMLs (simple-task, with-volumes, with-node-selector)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test(controller): add Kind integration tests for ReaperPod CRD
Phase 4b tests: CRD installation, controller deployment, ReaperPod
creation with Pod verification, status mirroring, exit code propagation,
annotation translation, kubectl column output, and GC on delete.
Also updates build-controller-image.sh to match agent build pattern
(--cluster-name, --skip-build, --quiet) and wires controller image
build into phase_setup.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: update CRD plan — all 10 steps complete
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat(test): add --crd-only flag for fast CRD controller test iteration
Skips cargo tests, integration tests, and agent tests — runs only
Phase 4b controller tests (CRD install, ReaperPod lifecycle, status
mirroring, annotation translation, GC).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(test): ensure reaper-system namespace exists for --crd-only runs
The controller deployment targets the reaper-system namespace, which is
normally created during agent setup. When running with --crd-only, agent
setup is skipped, causing "namespace not found" errors. Create the
namespace idempotently before applying the controller manifest.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: update examples and docs for CRD controller tests
- CLAUDE.md: add controller binary, CRD types, scripts, and example 09
to project structure; document Phase 4b in integration test phases
- TESTING.md: add --crd-only and --agent-only flags; add Phase 4b
controller tests; add CRD iteration example
- examples/README.md: add 09-reaperpod section with usage instructions
- examples/09-reaperpod/simple-task.yaml: add namespace prerequisite
- docs/CRD_PLAN.md: note namespace fix for --crd-only runs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat(playground): add --with-controller flag for ReaperPod CRD setup
Installs the ReaperPod CRD, builds and loads the controller image into
Kind, and deploys the reaper-controller. Adds CRD usage examples to the
playground summary output.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat(playground): make CRD and controller setup the default
The ReaperPod CRD and reaper-controller are now installed by default
when setting up a playground cluster. Remove the --with-controller flag
since this is the standard mode of operation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(playground): add --context to all kubectl examples in summary
Use --context=kind-<cluster-name> in all example commands so they work
correctly when multiple Kind clusters are running. Also add an inline
ReaperPod one-liner example.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(controller): use fixed Pod name matching ReaperPod name
Replace generateName with a fixed name so the Pod created by the
controller has the same name as the ReaperPod. This enables
`kubectl logs <reaperpod-name>` to work directly without needing
to look up the Pod name from the ReaperPod status.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat(helm): replace Ansible with Helm chart for installation
Add a Helm chart (deploy/helm/reaper/) that installs everything needed
to run Reaper: node DaemonSet with init container for binary installation,
controller Deployment, CRDs, RuntimeClass, and RBAC.
- Add Dockerfile.node and scripts/install-node.sh for init container
- Add scripts/build-node-image.sh for Kind image builds
- Rewrite setup-playground.sh to use Helm instead of Ansible
- Update test-phases.sh to use Helm-based setup
- Make CRD/controller tests idempotent (work with Helm or standalone)
- Mark Ansible deployment as DEPRECATED (kept but no longer default)
- Update README.md and CLAUDE.md to reflect Helm as default
All 8 CRD integration tests pass with the new Helm-based flow.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: update all references from Ansible to Helm
Update TESTING.md, RELEASING.md, and deploy/kubernetes/README.md to
reflect Helm as the default installation method. Mark Ansible references
as deprecated throughout.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* ci: remove playground-release job (--release flag removed)
setup-playground.sh no longer supports --release (Helm handles
installation). Remove the CI job that tested release resolution modes.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* ci: build reaper-controller in CI, replace Ansible with Helm
- Add --features controller --bin reaper-controller to musl build step
- Include reaper-controller in uploaded artifacts
- Replace 'Install Ansible' step with 'Install Helm' for kind-integration
The controller binary was missing from CI artifacts, causing
build-controller-image.sh --skip-build to fail in kind-integration.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(test): replace yield_now with 50ms sleep to avoid ETXTBSY flake
yield_now() is insufficient under CI load — the kernel may still hold
the inode after chmod. A small sleep reliably avoids the ETXTBSY race
when exec'ing a freshly-written shell script.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* ci: increase kind-integration timeout from 20 to 30 minutes
With CRD controller tests (Phase 4b) added on top of agent GC tests
(some taking 90-120s each), 20 minutes is too tight. Increase to 30
minutes to give the full suite room to complete.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* docs: add CI test runtime optimization to TODO
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* ci: retrigger CI pipeline
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
**Local development (building from source natively):**
290
273
- All of the above, plus [Rust](https://www.rust-lang.org/tools/install) (toolchain version pinned in `rust-toolchain.toml`)
@@ -305,7 +288,7 @@ cargo test
305
288
306
289
## Configuration
307
290
308
-
Reaper reads configuration from `/etc/reaper/reaper.conf` on each node. The Ansible installer creates this file automatically. Environment variables of the same name override file values.
291
+
Reaper reads configuration from `/etc/reaper/reaper.conf` on each node. The Helm chart creates this file automatically via the node DaemonSet init container. Environment variables of the same name override file values.
0 commit comments