DEV Community

Menshikov Vasil
Menshikov Vasil

Posted on Originally published at dorokhovich.com

Local Kubernetes Dev — Part 14: Preparing for deployment and CI

"I pushed a new image under the same :latest, ran kubectl apply — and nothing changed in the cluster." Why?

Kubernetes triggers a rollout only if the pod template changed. The line image: myapp:latest didn't change — so as far as the cluster is concerned there's nothing to deploy, even though the registry already holds a different image. Worse, on a pod restart latest can pull a new (possibly broken) version — on its own, without a deploy from you. Prod changes versions "all by itself."

In the new article (part 14) — the bridge from a fast local loop to a repeatable deploy:
• one manifest base + per-environment overlays (Helm values vs Kustomize patches), no copy-paste and no config drift;
• why latest in prod is pain, and what to use instead: immutable tags (sha, semver, digest) + docker/metadata-action;
• a minimal CI on GitHub Actions: build → push → apply;
• an explicit breakdown: what moves from local, what's prod-only, and what you must NOT drag into prod (Tilt live-update, uvicorn --reload, debug ports);
• the three weaknesses of push-based CI (keys in CI, drift, manual rollback) — and why they lead to GitOps.

Read it: https://dorokhovich.com/blog/local-k8s-preparing-for-deployment-and-ci?utm_source=devto&utm_medium=syndication&utm_campaign=local-k8s-preparing-for-deployment-and-ci

Top comments (0)