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

Add caching to improve build time performance #260

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

adamus1red
Copy link
Contributor

Uses the builtin cache-from/cache-to options from the docker/buil-push-action to write out the buildx cache.
Using the github actions/cache action the buildx cache is stored by github for future runs.

@qdm12
Copy link
Owner

qdm12 commented Nov 7, 2021

Hey there, thanks for your PR!

However, having toyed around with buildx caching a few months ago, it always turned out to be slower than without cache, at least for Go projects where things are usually quick to download/test/build. What do you think? I can merge it and compare publish time by doing another commit on top too.

If that turns out to be faster, I can modify the verify job to use buildx and we can try adding caching there too.

- Cache base image layers only
- Cache for verify job only
- Do not cache for publish job since:
  - most of the work is cross compiling
  - go.mod often change between publish jobs
  - prevent bugs introduced due to the cache (unlikely)
@qdm12 qdm12 force-pushed the adamus1red/build-caching branch 6 times, most recently from e835d1b to c7757c8 Compare June 17, 2023 14:31
@qdm12 qdm12 force-pushed the master branch 3 times, most recently from 0ab3d3c to 010634d Compare January 19, 2024 11:43
@qdm12 qdm12 force-pushed the master branch 2 times, most recently from fd15083 to 5c166a6 Compare January 28, 2024 12:10
@qdm12 qdm12 force-pushed the master branch 2 times, most recently from bed663a to 6a6b1a8 Compare February 13, 2024 10:42
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.

None yet

2 participants