Skip to content

Build and push multi-platform docker image#1567

Merged
sbc100 merged 1 commit into
emscripten-core:mainfrom
radiantly:multiplatform
Sep 25, 2025
Merged

Build and push multi-platform docker image#1567
sbc100 merged 1 commit into
emscripten-core:mainfrom
radiantly:multiplatform

Conversation

@radiantly
Copy link
Copy Markdown
Contributor

This PR adds the publish-docker-image-multiplatform CI job step that pushes a multi-platform docker image when a new tag is created. #1211

Unfortunately, this is not as simple as pushing two images targeting different platforms to the same tag. There are a couple of ways to create a multi-platform image:

  • Using docker buildx to build images for all platforms. To do this images targeting non-native platforms would need to be built using QEMU (slower), a remote machine or cross-compilation.
  • Building and publishing platform-specific images emscripten/emsdk-x64, emscripten/emsdk-arm64 and then creating a manifest that links to these images. This is the simpler solution to implement, and is what this PR does.

Tested with CircleCI on my fork. See the pushed images at radiantly/emsdk · DockerHub

@sbc100
Copy link
Copy Markdown
Collaborator

sbc100 commented Jun 13, 2025

Nice! Thanks for working on this.

@tdrz
Copy link
Copy Markdown

tdrz commented Sep 24, 2025

Any chance this will be merged?

Copy link
Copy Markdown
Collaborator

@sbc100 sbc100 left a comment

Choose a reason for hiding this comment

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

Sorry, I had some old comments that never code sent.

Comment thread .circleci/config.yml Outdated
Comment thread .circleci/config.yml Outdated
Comment thread docker/Makefile Outdated
@sbc100 sbc100 merged commit 44f11ea into emscripten-core:main Sep 25, 2025
12 checks passed
mmorel-35 pushed a commit to mmorel-35/emsdk that referenced this pull request Feb 3, 2026
This PR adds the `publish-docker-image-multiplatform` CI job step that
pushes a multi-platform docker image when a new tag is created. emscripten-core#1211

Unfortunately, this is not as simple as pushing two images targeting
different platforms to the same tag. There are a couple of ways to
create a multi-platform image:
- Using `docker buildx` to build images for all platforms. To do this
images targeting non-native platforms would need to be built using QEMU
(slower), a remote machine or cross-compilation.
- Building and publishing platform-specific images
`emscripten/emsdk-x64`, `emscripten/emsdk-arm64` and then creating a
manifest that links to these images. This is the simpler solution to
implement, and is what this PR does.

Tested with CircleCI on my fork. See the pushed images at
[radiantly/emsdk ·
DockerHub](https://hub.docker.com/r/radiantly/emsdk/tags)
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.

3 participants