Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build multi-arch docker image for x64-64 and ARM64 #507

Merged
merged 9 commits into from
Apr 16, 2024

Conversation

mludvig
Copy link
Contributor

@mludvig mludvig commented Apr 15, 2024

Enable build of ARM64 image for use on MacBook with apple silicon (M1, M2, M3). It's about 3x faster than running the x86-64 container on the Apple silicon under Rosetta emulation.

Copy link

vercel bot commented Apr 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
big-agi-open ✅ Ready (Inspect) Visit Preview Apr 16, 2024 4:53am

@enricoros
Copy link
Owner

@mludvig does this replace the current images, or adds to them? This workflow is used for the official images in the project page.

@mludvig
Copy link
Contributor Author

mludvig commented Apr 16, 2024

@enricoros It builds a multi-arch image. Technically 2 separate images, one for x86-64 and one for arm64 but both have the same name (e.g. big-agi:latest) and the correct platform is pulled based on which arch you're running on.

This won't change the existing images but the next time you release a new version a multi-arch will be created. It should be completely transparent to the users.

My test build is: ghcr.io/mludvig/big-agi:sha-7643770 - you can give it a try.

@enricoros
Copy link
Owner

Thanks, this is very useful and the explanation as well. On the nature of the change itself:

  • removing the comments at the beginning?
  • changing the versions of many docker images? (I read pinned versions are more secure)

@mludvig
Copy link
Contributor Author

mludvig commented Apr 16, 2024

Using "@v5" is a bit more flexible as it may eventually get security or stability updates while being backwards compatible within the v5.x line. These versions were tested and worked for me.

But if you prefer to keep your hashes and put the comments back I can update the PR. Up to you.

@mludvig
Copy link
Contributor Author

mludvig commented Apr 16, 2024

@enricoros I've cleaned up the unrelated changes and only left the multi-arch stuff in.

@enricoros enricoros merged commit 3769a53 into enricoros:main Apr 16, 2024
1 check passed
@enricoros
Copy link
Owner

Thanks @mludvig - merged

@mludvig mludvig deleted the arm-build-1 branch April 16, 2024 05:20
@enricoros enricoros added this to the 1.16.0 milestone May 7, 2024
@enricoros enricoros mentioned this pull request May 9, 2024
24 tasks
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.

2 participants