Standardize Dockerfile and Makefile for improved platform handling - #1366
Open
dharsanb wants to merge 3 commits into
Open
Standardize Dockerfile and Makefile for improved platform handling#1366dharsanb wants to merge 3 commits into
dharsanb wants to merge 3 commits into
Conversation
…ling Signed-off-by: Dharsan Baskar <git@dharsanb.com>
evrardjp
previously approved these changes
Jun 13, 2026
evrardjp
left a comment
Collaborator
There was a problem hiding this comment.
I will test this but it looks nice.
Do you want to add docs or a specific make target for arm?
evrardjp
reviewed
Jul 3, 2026
Signed-off-by: Dharsan Baskar <git@dharsanb.com>
evrardjp
reviewed
Jul 6, 2026
evrardjp
left a comment
Collaborator
There was a problem hiding this comment.
Wont' this break the release?
evrardjp
reviewed
Jul 6, 2026
| dev-image: | ||
| mkdir -p dist/docker/$(LOCAL_PLATFORM) | ||
| CGO_ENABLED=0 go build -trimpath -ldflags "-s -w -X main.version=$(VERSION)" -o dist/docker/$(LOCAL_PLATFORM)/kured ./cmd/kured | ||
| mkdir -p dist/docker |
Collaborator
There was a problem hiding this comment.
Couldn't we just keep LOCAL_PLATFORM (adapt it to linux/$(shell go env GOARCH)),
keep the mkdir -p dist/docker/$(LOCAL_PLATFORM) ,
merge your adaptation: CGO_ENABLED=0 GOOS=linux go build -trimpath -ldflags "-s -w -X main.version=$(VERSION)" -o dist/docker/$(LOCAL_PLATFORM)/kured ./cmd/kured
and keep $(SUDO) docker buildx build --load --platform $(LOCAL_PLATFORM) -t $(DEV_IMAGE) dist/docker ?
wouldn't that work?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In this PR
DOCKER_LOCAL_PLATFORMis added to handle arch based on the machine archGOOS=linuxto build for linux containers instead of the default platform GOOS