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
Cache generate-assets
output in CI
#1081
Conversation
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.
It looks good from the workflow. I'm still a bit hesitant since we can't test saving the cache until deployment.
We did some testing (thanks @TrialDragon!). Saving and using the cache worked well, but we were unable to test using it with merge queues because it is a feature restricted to Github orgs and private repos. Another note: using the cache reduces |
Caches cannot be overwritten after their creation, so the date ensures the cache is refreshed daily. This is especially true since `deploy.yml` is scheduled to run daily anyways, so there will always be a cache available for `ci.yml`.
I don't think `deploy.yml` should use any cached data, in case it ever becomes invalid. This is why `deploy.yml` only stores the cache. By deleting the crates.io cache, it may increase deploy times. If this becomes an issue, I'll make a follow-up PR and undo this change.
This reverts commit 1914571.
Closes #1066.
This adds a cache for
generate-assets
, which is the CI job currently takes the longest at ~7 minutes, and reduces its runtime to 11 seconds. The cache is updated ever time the website is deployed usingdeploy.yml
. The cache is then used inci.yml
when no run in the merge queue.