kubectl, one Kubernetes minor per tag, rebuilt weekly and signed. A drop-in for bitnami/kubectl.
1.9K
kubectl for pipelines and Helm hooks: one Kubernetes minor per tag, rebuilt every week, signed, and laid out like bitnami/kubectl, so a chart written for that image runs on this one unchanged.
bitnami/kubectl has published one tag since August 2025: latest. Its versioned tags stopped at 1.33.4 on 2025-08-22 and live on, unmaintained, as bitnamilegacy/kubectl, pulled 21.6 million times by 2026-10-26. A chart or pipeline that pinned bitnami/kubectl:1.33 stopped receiving security fixes that day, and one that switched to latest now gets whatever kubectl minor ships next, which kubectl's one-minor version skew policy does not promise will talk to its cluster.
docker run --rm heyvaldemar/kubectl:1.37 version --client
docker run --rm -v ~/.kube/config:/.kube/config:ro heyvaldemar/kubectl:1.37 get nodes
In a chart that used bitnami/kubectl:<version>, change the repository and pick the minor of your cluster:
image:
repository: heyvaldemar/kubectl
tag: "1.37"
| Tag | What it is | Moves |
|---|---|---|
1.37, 1.36, 1.35 | the three newest Kubernetes minors, the window upstream supports | every week and on every change here, with the minor's current patch release and Debian's security updates; never to another minor |
1.37.1 | one patch release | every week, with Debian's security updates, while it is its minor's current patch |
latest | the newest minor | as 1.37, and to the next minor the week it ships |
Every tag moves, so a pinned tag keeps receiving security fixes. For an image that never changes, pin its digest:
docker buildx imagetools inspect heyvaldemar/kubectl:1.37 --format '{{.Manifest.Digest}}'
A minor that falls out of the newest three keeps its last image and stops moving. Images are linux/amd64 and linux/arm64.
Charts depend on how the image runs, not only on kubectl. This one keeps what bitnami/kubectl did:
1001 with group 0, so it also runs under an arbitrary UID in group 0 (OpenShift);kubectl and the command --help, so args: ["get", "pods"] works as it did;HOME=/, with /.kube writable by group 0, so a kubeconfig mounted at /.kube/config is found and kubectl's discovery cache works;/opt/bitnami/kubectl/bin/kubectl and /opt/bitnami/common/bin/yq run.It is checked, not claimed. tests/drop-in-test.sh runs on every build against the last versioned Bitnami image, bitnamilegacy/kubectl:1.33.4: the same user, entrypoint, command and HOME, the same calls a hook makes, and every executable on its PATH on this one's. The ones that are not here are named in tests/drop-in-absent.tsv, each with its reason: Bitnami's own package scripts, and tools Debian 13 no longer ships in its slim base (apt-key, adduser, util-linux extras). The test fails on any absence without a reason.
A hook that calls only kubectl does not need this image. The Kubernetes project publishes registry.k8s.io/kubectl:v1.37.1: kubectl and nothing else, no shell. Use that one. This image is for hooks that run bash -c with jq, yq or envsubst around kubectl.
Before anything is published, each build is compared with the image already published under its tag (scripts/contract-test.sh): every executable on its PATH, its user, HOME, working directory, entrypoint and command, and kubectl on the tag's minor and no older. A removal has to be named in tests/contract-removed.tsv and in the changelog. Each test is shown the breaks it exists for (tests/plants.tsv, run in CI): the image running as root, jq or the procps tools left out, a Bitnami path gone, /.kube not writable, another entrypoint, HOME moved, a yq binary with another checksum, a kubectl that is not the version the image says.
Dockerfile. Neither is installed if it does not match.release-assets.yml calls by tag (@v2.1.0), because it verifies its own reference at run time and refuses a SHA.cosign verify heyvaldemar/kubectl:1.37 \
--certificate-identity-regexp "https://github.com/heyvaldemar/kubectl-docker/.*" \
--certificate-oidc-issuer "https://token.actions.githubusercontent.com"
docker build --build-arg KUBE_VERSION=v1.37.1 -t kubectl:local .
./scripts/smoke-test.sh kubectl:local
./tests/drop-in-test.sh kubectl:local
./scripts/contract-test.sh kubectl:local heyvaldemar/kubectl:1.37 1.37
KUBE_VERSION is required; the build refuses to guess.
Report a bug or ask for a change in issues. Pull requests are welcome: every test above runs on them before anything can merge. Report a vulnerability privately, as SECURITY.md describes.
heyvaldemar/aws-kubectl is the same idea with the AWS CLI beside kubectl, for EKS pipelines, and the same weekly lines (kube-1.37).
Maintained by Vladimir Mikhalev · Docker Captain · CNCF Ambassador · IBM Champion · AWS Community Builder
Content type
Image
Digest
sha256:867995834…
Size
87.1 MB
Last updated
about 8 hours ago
docker pull heyvaldemar/kubectl