Skip to content

Build images on base image for target platform#1360

Merged
nickysemenza merged 1 commit intocloudflare:masterfrom
killianmuldoon:pr-fix-docker-build
Mar 5, 2024
Merged

Build images on base image for target platform#1360
nickysemenza merged 1 commit intocloudflare:masterfrom
killianmuldoon:pr-fix-docker-build

Conversation

@killianmuldoon
Copy link
Copy Markdown
Contributor

This change ensure the docker image is built on the same architecture that it's building for. This ensures that other tools in the docker image - e.g. bash - will be usable in the image.

Fixes #1359

Signed-off-by: killianmuldoon <cilliancapi@gmail.com>
@@ -1,4 +1,4 @@
FROM golang:1.20
FROM --platform=${TARGETPLATFORM} golang:1.20
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested that golang images are available for all platforms currently supported - linux/arm64, linux/s390x and linux/amd64

@nickysemenza nickysemenza merged commit 44b96cf into cloudflare:master Mar 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: cfssl/cfssl image builds with wrong base arch

2 participants