darklynx / request-baskets

HTTP requests collector to test webhooks, notifications, REST clients and more ...
https://rbaskets.in
MIT License
339 stars 52 forks source link

Provide ARM based image on docker hub #58

Open everflux opened 4 years ago

everflux commented 4 years ago

It would be very convenient if you could provide a multi arch image on docker hub, so that ARM is supported as well.

darklynx commented 4 years ago

that make sense 👍 do you have any hints on how to achieve that or any article that descries how to do it right with docker hub?

everflux commented 4 years ago

You could look into how I did it with a DockerHub based build here: https://github.com/trion-development/docker-ng-cli A (german, but google translate should work) description is here: https://www.trion.de/news/2019/10/14/docker-multi-arch-dockerhub.html

maaroen commented 1 year ago

I'm also interested in this, is there any progress on it?

I could send you a sample command to build for arm64 if needed, I just have a startup issue with it

maaroen commented 1 year ago

This is how I made a working ARM64 image:

So basically the only change I would assume to be needed is the GOARCH value in the dockerfile. Is setting this value actually needed, or could this be retrieved from the operating system? If this is the case then you can easily make multiplatform builds using this command:

docker buildx build --tag registry.xxx.nl/request-baskets:latest --tag registry.xxx.nl/request-baskets:1.2.3 --platform linux/arm64 --platform linux/amd64 --progress=plain --file docker/multistage/Dockerfile --push .
darklynx commented 1 year ago

I wonder if all that can be automated via GitHub actions and results are hosted on GitHub container registry.

Unfortunately dont have time to look at it, but PR or a link to a simple example are highly appreciated :)