Repository navigation
Description
What happened
Nothing stops a :latest image tag from coming back under k8s/. No CI workflow and no devops ci step runs kube-linter or Checkov over the manifests. #711 rejected a Checkov CKV_K8S_14 step: the service image ghcr.io/dan-petty/devops-cli/service has no tag in Git by design (k8s/README.md, "Service Image Updates": Argo CD Image Updater sets its tag and digest), so CKV_K8S_14 fails on it.
What should happen
CI fails when a manifest under k8s/ names an image with the :latest tag, and it passes for an untagged image that Argo CD Image Updater pins.
Evidence
- kube-linter 0.8.3 is pinned in
tools.lock. Its defaultlatest-tagblock list is.*:(latest)$,^[^:]*$and(.*/[^:]+)$, so it also blocks the untagged service image:kube-linter lint k8s/devops/cronjob.yamlreportslatest-tag. - A custom kube-linter check from the
latest-tagtemplate with the block list.*:(latest)$alone gives the wanted result. grep -rnE 'image:.*:latest' k8s/finds no match today.
Scope
- A kube-linter config with the custom check, and one CI step that runs the pinned kube-linter with it.
- CI must not run it through
devops k8s lintuntil that command stops passing on findings and on a missing binary (the issue filed with this one).
Proposed design
Problem statement
Nothing in CI stops a :latest image tag from appearing in Kubernetes manifests under k8s/. The default kube-linter latest-tag check blocks untagged images as well, which breaks the service image that Argo CD Image Updater pins. A custom kube-linter check and one CI step are needed to catch :latest tags while passing untagged images.
Acceptance criteria
- Criterion 1: A kube-linter config file defines a custom
latest-tagcheck with the block list.*:(latest)$only.
Verification: Read the config file and confirm thelatest-tagcheck uses the block list.*:(latest)$and no other patterns. - Criterion 2: A CI step runs the pinned kube-linter 0.8.3 with the custom config over the
k8s/directory.
Verification: Read the CI workflow file and confirm the step invokes kube-linter 0.8.3 with the custom config targetingk8s/. - Criterion 3: CI fails when a manifest under
k8s/names an image with the:latesttag.
Verification: Add a test manifest withimage: example/app:latestunderk8s/, run the CI step, and confirm it exits non-zero with alatest-tagfinding. - Criterion 4: CI passes for the untagged service image
ghcr.io/dan-petty/devops-cli/service.
Verification: Run the CI step against the existingk8s/manifests and confirm it exits zero with nolatest-tagfinding on the service image. - Criterion 5: The CI step does not invoke
devops k8s lint.
Verification: Read the CI workflow file and confirm no step callsdevops k8s lint.
Key questions
- What block list does the custom
latest-tagcheck use?: The block list is.*:(latest)$only. This matches images tagged:latestand does not match untagged images such as the service image. [sources: k8s/devops/cronjob.yaml] - Why does the default kube-linter
latest-tagcheck not work here?: The default block list includes^[^:]*$and(.*/[^:]+)$, which match untagged images. The service image is untagged by design, so the default check fails on it. [sources: k8s/devops/cronjob.yaml, openspec/changes/archive/2026-10-24-711-bounded-shared-valkey/proposal.md] - Why was Checkov
CKV_K8S_14rejected for this purpose?: CheckovCKV_K8S_14fails on the untagged service image, which is untagged by design. Argo CD Image Updater sets the tag and digest at runtime. [sources: openspec/changes/archive/2026-10-24-711-bounded-shared-valkey/proposal.md, k8s/devops/cronjob.yaml] - Should the CI step use
devops k8s lint?: No. The CI step must invoke kube-linter directly. Thedevops k8s lintcommand passes on findings and on a missing binary, and a separate issue addresses that. (proposed)
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsReady
- StatusShow more project fieldsNew
Activity
dan-petty commentedon Oct 24, 2026
Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones on the board.
The candidate modifies CI behavior for Kubernetes manifests and uses kube-linter tooling which are infrastructure concerns.This change improves CI reliability but does not block releases or introduce security issues.Preventing :latest tags in manifests improves deployment stability and avoids potential runtime issues.The change only requires adding a kube-linter check to CI which is a small modification.Both items work on k8s/ image handling but the candidate focuses on preventing :latest tags and item #1994 verifies image existence before merge.dan-petty commentedon Oct 28, 2026
Status set to Ready at bb46660 (see proposed design in issue body).
chore(main): release 0.15.0 (#2623)