1---2name: kubernetes3description: Use when editing tracked AKS, Kubernetes, Helm, Kustomize, or generated GitOps manifests.4---56<!-- Generated from harness/github-copilot/plugins/open-horizons-platform/instructions/kubernetes.instructions.md by harness/claude-code/scripts/convert_from_copilot.py. Edit the source, not this file. -->78# Kubernetes and Helm910## Conventions1112- Use explicit versioned image tags; never use `latest`.13- Apply standard `app.kubernetes.io/*` labels consistently to workloads, services, selectors, monitoring, and policy targets.14- Set realistic resource requests and limits plus startup, readiness, and liveness probes that match the service contract.15- Run as non-root, disallow privilege escalation, drop capabilities, use `RuntimeDefault` seccomp, and prefer a read-only root filesystem.16- Use dedicated service accounts, namespace-scoped RBAC, Workload Identity, and least-privilege network policies.17- Reference secrets through External Secrets or approved Key Vault integration; never commit a Kubernetes Secret value.18- Keep namespaces, selectors, ports, service names, and Helm value keys consistent across related manifests.19- Keep generated GitOps examples under `scripts/golden-paths/`; no root `argocd/` path is assumed.20- Preserve rollout safety with disruption budgets, topology constraints, and graceful termination where availability requires them.2122## Verification2324- YAML, Helm, and Kustomize rendering produce valid resources with no unresolved tokens.25- Policy checks cover tags, resources, non-root execution, privilege, and registry restrictions.26- Rendered workloads have immutable images, probes, resources, identity, and secret references.2728## Do / Do Not2930| Do | Do not |31| --- | --- |32| Render manifests and enforce identity, resources, probes, and policy controls. | Apply unrendered files or weaken controls to make a deployment pass. |33| Use immutable images and external secret references. | Use floating tags or commit secret values. |3435## Checklist Before Opening a PR3637- [ ] The change matches this instruction's `applyTo` scope.38- [ ] YAML, Helm, and Kustomize rendering pass without unresolved tokens.39- [ ] Policy checks cover identity, privilege, network, resources, and registry rules.40- [ ] Workloads use immutable images, probes, and external secret references.41- [ ] No unrelated edits or unresolved placeholders remain.