-
Notifications
You must be signed in to change notification settings - Fork 464
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
*: Add sds and envoyinit to the release pipeline #10509
*: Add sds and envoyinit to the release pipeline #10509
Conversation
f668023
to
d9457fa
Compare
- uses: "docker/setup-qemu-action@v3" | ||
- uses: "docker/setup-buildx-action@v3" |
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.
Needed for the SDS container build. Otherwise, the release action was failing when I was testing this out in my fork: https://github.com/timflannagan/kgateway/actions/runs/12942255998/job/36099680490.
# BASE_IMAGE used in non distroless variants | ||
ALPINE_BASE_IMAGE ?= alpine:3.17.6 | ||
# BASE_IMAGE used in non distroless variants. Exported for use in goreleaser.yaml. | ||
export ALPINE_BASE_IMAGE ?= alpine:3.17.6 |
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.
We talked about migrating away from alpine in favor of distroless or some other base image. I held off for now as I want to focus on getting the full release pipeline working e2e before standardizing on our approach for base images.
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.
Can we track removing alpine explicitly in an issue? Either to the release automation or the cleanup epic, whichever makes more sense to you.
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.
Yep, will do.
&& rm -rf /var/log/*log /var/lib/apt/lists/* /var/log/apt/* /var/lib/dpkg/*-old /var/cache/debconf/*-old | ||
|
||
COPY envoyinit-linux-$GOARCH /usr/local/bin/envoyinit | ||
|
||
# SDS-specific setup, only used if ENVOY_SIDECAR=true | ||
COPY docker-entrypoint.sh / | ||
ARG ENTRYPOINT_SCRIPT=/docker-entrypoint.sh |
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.
This was needed as goreleaser's extra_files argument adds the path (e.g. projects/envoyinit/cmd/docker-entrypoint.sh in this case) to the build context, while this regular envoyinit-docker Makefile target fails if I hardcode the COPY projects/envoyinit/cmd/docker-entrypoint.sh /
instruction.
@@ -43,11 +73,69 @@ dockers: | |||
- "--platform=linux/amd64" | |||
- "--build-arg=GOARCH=amd64" | |||
- "--build-arg=ENVOY_IMAGE={{ .Env.ENVOY_GLOO_IMAGE }}" | |||
- image_templates: |
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.
nit: can we put the images in the same order as controller image (i.e. arm first), so it's easier to read?
- image_templates: | ||
- &sds_amd_image "{{ .Env.IMAGE_REGISTRY }}/{{ .Env.SDS_IMAGE_REPO }}:{{ .Env.VERSION }}-amd64" | ||
use: buildx | ||
dockerfile: &sds_dockerfile projects/sds/cmd/Dockerfile |
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.
looking at the controller image above, there's the extra dockerfile arg for arm but not amd; why is it the other way around here?
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.
@jenshu Hmm, I'm not sure I follow. I didn't see any skew in the diff.
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.
well, it's fixed now that you swapped amd and arm :)
Signed-off-by: timflannagan <[email protected]>
Signed-off-by: timflannagan <[email protected]>
d9457fa
to
c8f59c1
Compare
Messed my branch up locally. Just pushed a commit for ordering the config more consistently. |
Description
Update the .goreleaser.yaml configuration and add the sds and envoy init containers to the release pipeline. See #10441 for the high-level tracker for this stream of work.
Related to #10423.
Checklist: