-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hubble: fix Hubble Relay BASE_IMAGE #23636
hubble: fix Hubble Relay BASE_IMAGE #23636
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Alex, LGTM!
Note that BASE_IMAGE
being overwritten to scratch
was never caught up as all images using BASE_IMAGE
as ARG
were actually based on scratch
up to recently when Hubble Relay's base image was changed to distroless static.
f3261fe
to
6003d73
Compare
This reverts commit fc2ce0f. Hubble Relay's base image, distroless nonroot, already set WORKDIR to /home/nonroot so setting it in the Hubble Relay Dockerfile is a no-op: % docker image inspect -f '{{.Config.WorkingDir}}' gcr.io/distroless/static-debian11:nonroot /home/nonroot Signed-off-by: Alexandre Perrin <alex@isovalent.com>
95a4d37 ("hubble-relay: use distroless as the base image and run as non-root") attempted to use distroless as base image for Hubble Relay instead of scratch. However, when running `make docker-hubble-relay-image` the image would be built with `--build-arg BASE_IMAGE=scratch` effectively overriding the base image "back" to scratch. This patch make it so BASE_IMAGE is only overridden when set, and honor the Dockerfile's BASE_IMAGE otherwise. Signed-off-by: Alexandre Perrin <alex@isovalent.com>
Before this patch, it was not possible to disable gops for Hubble Relay through Helm. Signed-off-by: Alexandre Perrin <alex@isovalent.com>
6003d73
to
f256fad
Compare
/test Job 'Cilium-PR-K8s-1.16-kernel-4.9' hit: #22578 (97.53% similarity) |
/test-1.16-4.9 EDIT: previous run hit #22578 |
/ci-gke EDIT: previous run hit #22368 |
/ci-verifier EDIT: previous run stuck in Expected — Waiting for status to be reported |
@kaworu FYI, you don't have to rerun the test if they failed with a known flake and it's clear it's unrelated. |
95a4d37 ("hubble-relay: use distroless as the base image and run as non-root") attempted to use distroless as base image for Hubble Relay instead of
scratch
.However, when running
make docker-hubble-relay-image
the image would be built with--build-arg BASE_IMAGE=scratch
effectively overriding the base image "back" toscratch
.This patch make it so
BASE_IMAGE
is only overridden when set, and honor the Dockerfile'sBASE_IMAGE
otherwise.Fix #23374, #23533