Development¶
Prerequisites¶
- Go >= 1.25 (toolchain pin in
go.mod) - mise, runtime + tool manager
- just, task runner (provisioned by
mise install) - A local Kubernetes cluster: Kind or Minikube
Bring up a dev cluster¶
mise install # provisions Go, kubectl, helm, kind, just, kubeconform
just dev-up # creates Kind cluster, builds + loads images, installs the chart
Apply a sample CR:
kubectl apply -f config/samples/targets/podinfo.yaml
kubectl apply -f config/samples/scalevalidation-servicedefault.yaml
Tear down:
Common tasks¶
| Command | Purpose |
|---|---|
just check |
tidy + lint + unit tests, required before every commit |
just test-integration |
envtest suite (downloads apiserver + etcd assets) |
just test-e2e |
full verdict E2E in Kind |
just generate |
regenerate zz_generated.deepcopy.go |
just manifests |
regenerate CRD + RBAC YAML from kubebuilder markers |
just docs-serve |
generate the API reference and serve the docs site locally |
Run just generate && just manifests after any change to api/v1beta1/*_types.go.
Documentation¶
The docs site is MkDocs Material. The API reference page is generated from the kubebuilder markers by crd-ref-docs and is not committed (it is regenerated on every build).
just docs-api # regenerate docs/reference/api.md
just docs-serve # generate API ref + live-reload server on :8000
just docs-build # generate API ref + build static site into ./site
See Contributing for the pull request workflow.