-
-
Notifications
You must be signed in to change notification settings - Fork 19
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
Improve docker building workflow #165
Conversation
WalkthroughThe recent updates to the GitHub Actions workflow focus on renaming jobs and steps, updating action versions, and modifying tag values for Docker image builds. These changes aim to improve clarity, maintain up-to-date dependencies, and ensure proper testing of Docker images. Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- .github/workflows/docker-build.yml (2 hunks)
Additional comments not posted (12)
.github/workflows/docker-build.yml (12)
10-10
: Jobtest-docker-image
has been renamed frompush-docker-image
.The renaming clarifies the job's purpose, which is to test the Docker image rather than push it.
14-15
: Updatedactions/checkout
to versionv4.1.5
.Keeping actions up-to-date ensures compatibility and access to the latest features and fixes.
17-18
: Updateddocker/setup-buildx-action
to versionv3.3.0
.Updating to the latest version helps maintain compatibility and leverage new features.
20-28
: Updateddocker/build-push-action
to versionv5.3.0
and added caching scoped per platform.The update and caching improvements enhance build efficiency and reduce build times, especially for arm64 builds.
30-33
: Added step to install ALSA dummy module for testing the built image.This step ensures the necessary modules are available for testing the Docker image, improving test reliability.
Line range hint
35-45
: Added step to test the built amd64 image.Testing the built image ensures it functions correctly before proceeding to the push stage, improving overall workflow reliability.
47-48
: Jobpush-docker-image
now depends ontest-docker-image
.This dependency ensures that the image is tested before being pushed, improving the reliability of the deployment process.
56-57
: Updatedactions/checkout
to versionv4.1.5
.Keeping actions up-to-date ensures compatibility and access to the latest features and fixes.
59-64
: Updateddocker/login-action
to versionv3.1.0
.Updating to the latest version helps maintain compatibility and leverage new features.
66-68
: StepGenerate downcase repository name
remains unchanged.No changes detected in this step.
70-71
: Updateddocker/setup-buildx-action
to versionv3.3.0
.Updating to the latest version helps maintain compatibility and leverage new features.
73-83
: Updateddocker/build-push-action
to versionv5.3.0
and added caching scoped per platform.The update and caching improvements enhance build efficiency and reduce build times, especially for arm64 builds.
Speeds up the docker building process by utilizing one build agent per platform. In addition, better makes use of the github action caching by scoping it per platform. Since one platform would overwrite the other otherwise, resulting in low cache hit rates when building arm64. In addition, moved the testing of the docker image itself into its own job, which the building jobs are now dependent on.
Build times went from ~10 min down to ~2 min when running on github actions.