sling-cli icon indicating copy to clipboard operation
sling-cli copied to clipboard

Publish single Multiplatform Docker Image

Open johnoscott opened this issue 1 year ago • 2 comments

Since Sling 1.1.5 now supports arm/linux builds, the official docker image does not seem to pull the correct platform image.

docker run --rm slingdata/sling sling --version
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Version: 1.1.5

johnoscott avatar Feb 12 '24 00:02 johnoscott

I can workaround this issue by pulling the specific platform version.

docker pull --platform=linux/amd64/v8  slingdata/sling

but i shouldnt need to also specify the platform when i run it

docker run --rm slingdata/sling sling --version
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Version: 1.1.5

docker run --rm --platform=linux/amd64/v8 slingdata/sling sling --version
Version: 1.1.5

johnoscott avatar Feb 12 '24 00:02 johnoscott

Yes, was ripping my hair out trying to figure out this one. I can’t get goreleaser to properly release a multi-platform image. Will look at it later. For now, you can also pull slingdata/sling:1.1.5-arm64 without specifying platform.

Links for myself:

  • https://docs.docker.com/build/building/multi-platform/
  • https://goreleaser.com/cookbooks/cgo-and-crosscompiling/
  • https://www.docker.com/blog/faster-multi-platform-builds-dockerfile-cross-compilation-guide/

flarco avatar Feb 12 '24 00:02 flarco