k8s-templates
Provide starter files for a Kubernetes operator dev loop, including Tilt, Kustomize dev overlays, Make targets, and a minimal Dockerfile. Use when Codex needs to create or refresh local scaffolding ar
Files8
View on GitHubSKILL.mdskills/k8s-templates/SKILL.md
GitHubKubernetes Operator Templates
Copy or adapt the boilerplate under assets/ into the target repo.
Included Files
assets/Makefileassets/Tiltfileassets/Dockerfileassets/config/dev/kustomization.yamlassets/config/dev/manager_dev_patch.yaml
Adaptation Rules
- Change image names, module paths, and package paths to match the target repo.
- Keep the dev overlay on one replica with leader election disabled.
- Keep
allow_k8s_contexts(...)restricted to the intended local kind context. - Adjust the
go buildpackage path inTiltfileif the main package is not under./cmd. - If the container process is not PID 1, replace the live-update restart command with whatever actually restarts the manager.
Usage
- Copy the template files into the target repo.
- Copy the helper scripts from
$k8s-workflowinto the target repo or replace the Make targets with inline commands. - Update paths, image names, and namespace assumptions.
- Run
$k8s-workflowto use the templates in a full operator loop. - Read
references/template-notes.mdbefore changing the live-update behavior or overlay layout.