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

ci: rework multi-arch build #7

Merged
merged 8 commits into from
Dec 4, 2024

Conversation

SamyDjemai
Copy link
Contributor

@SamyDjemai SamyDjemai commented Nov 12, 2024

Some fixes to the currently failing Docker build workflow:

  • rather than relying on caching which wasn't set up properly, build and push specific arch images with their own cache, then merge them into usable tags in the merge job
  • setup proper GitHub token permissions for the whole workflow
  • add latest tag to the latest Docker builds on main

There are some example runs on my fork: SamyDjemai#2
We can see that, using caching, the ARM64 build job drops from 3 hours to 4 minutes! (We will avoid these long build times when ARM64 hosted runners will be available for OSS projects).

@SamyDjemai SamyDjemai marked this pull request as draft November 12, 2024 09:11
@SamyDjemai SamyDjemai marked this pull request as ready for review November 12, 2024 13:18
@SamyDjemai
Copy link
Contributor Author

SamyDjemai commented Nov 12, 2024

Builds are failing due to insufficient GITHUB_TOKEN permissions as explained in this documentation. Should we set the workflow as approval only? Or should we restrict Docker image building/publishing to only happen on the main branch?

UPDATE: I've edited the workflow to only push images to GitHub Container Registry when on the main branch in this repo, or on any branch on forks.

@benley benley merged commit c402ddc into singlestore-labs:main Dec 4, 2024
5 checks passed
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