Skip to content
This repository has been archived by the owner on Jul 2, 2023. It is now read-only.

Release arm64 images #19

Closed
odidev opened this issue Mar 30, 2022 · 10 comments
Closed

Release arm64 images #19

odidev opened this issue Mar 30, 2022 · 10 comments

Comments

@odidev
Copy link
Contributor

odidev commented Mar 30, 2022

Hi Team,

I am working on enabling arm64 testing support in the consul repository. It uses this image to test envoy tests. Currently, the Socat image is not available for arm64. I have successfully built and tested the arm64 image with the below changes.

Commit: odidev@df5626f

It will be very helpful for arm64 users if the Socat image is released for arm64.

If the above changes looks good, I will raise a PR.

@ozbillwang
Copy link
Contributor

ozbillwang commented Mar 30, 2022

I understood the code, it runs fine from new M1 macbook, but I can't make it work with popular free pipeline tools, such as CircleCI, Travis, Gitlab CI , Github Action, etc.

I did a test code, but still can't work it out

https://github.com/ozbillwang/multi-arch-docker-build/blob/master/Makefile#L18-L22

@odidev
Copy link
Contributor Author

odidev commented Mar 31, 2022

@ozbillwang

I am able to successfully push your images to dockerhub with below change in dockerfile.

RUN apk --no-cache --update add ca-certificates \
  && cp /bin/run-parts /usr/bin/ \
  && update-ca-certificates

update-ca-certificates command was expecting run-parts binary to be in /usr/bin folder but for alpine it will be in /bin

@ozbillwang
Copy link
Contributor

ozbillwang commented Mar 31, 2022

i know, we can manually do that. It runs fine from new M1 macbook

But the way is not accepted. When we publish a image for public using, who know what you put inside the image, right?

Second, we have no time to maintain its release, need the automation way to trigger the build when new version released.

So we have to build and push the images via pipeline tools, and these pipeline need be public as well. So others can review the build logs and trust the result

Currently I can't make them work with any of these four popular cicd pipeline tools

  • circleci
  • github action
  • travis ci
  • gitlab

if you are interesting, you can follow my test repo (https://github.com/ozbillwang/multi-arch-docker-build) and improve it first.

if it works, I will apply the same to all alpine images under https://github.com/alpine-docker

@odidev
Copy link
Contributor Author

odidev commented Mar 31, 2022

@ozbillwang,

I have added a symlink for run-parts in dockerfile and pushed the image using Travis and CircleCI. No changes are required in buildx code mentioned in Makefile.

Commit: odidev/multi-arch-docker-build@d8c2b3d

Travis report: https://app.travis-ci.com/github/odidev/multi-arch-docker-build/jobs/565405565

CircleCI report: https://app.circleci.com/pipelines/github/odidev/multi-arch-docker-build/4/workflows/eaa3ae20-17db-47a4-a292-981b9e1e67a1/jobs/4

Image link: https://hub.docker.com/repository/docker/odidev/docker-on-ci/tags?page=1&ordering=last_updated

If required, I will raise a PR.

@ozbillwang
Copy link
Contributor

ozbillwang commented Apr 1, 2022

That's so cool

Never notice run-parts is the root cause. I will check.

@ozbillwang
Copy link
Contributor

Check the logs, no error, and images are pushed to Docker Hub, with multi-arch supported.

image

Can you raise the PR to that repo?

Thanks.

@odidev
Copy link
Contributor Author

odidev commented Apr 4, 2022

@ozbillwang,

I have raised a PR to that repo. Please review and let me know if any changes required.

@ozbillwang
Copy link
Contributor

@odidev

That PR works fine, apprecated.

Can you raise the PR for this repo?

Commit: odidev@df5626f

ozbillwang added a commit that referenced this issue Apr 10, 2022
ozbillwang added a commit that referenced this issue Apr 10, 2022
@ozbillwang
Copy link
Contributor

@odidev

the multi-arch build works.

I don't have ARM / M1 chip Mac, can you confirm?

image

ozbillwang added a commit that referenced this issue Apr 10, 2022
@odidev
Copy link
Contributor Author

odidev commented Apr 11, 2022

@ozbillwang,

Thanks. It is working perfectly in arm64.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants