-
Notifications
You must be signed in to change notification settings - Fork 100
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
caching the Docker image #35
Comments
hmmm that seems to be about building caching and running an image, i'm not sure if it applies to pulling, caching and running an image. is your use case caching within one workflow or across workflow? i've heard across workflow is like not possible |
I found a simple way to use caches on this action, so share it here. The solution is to set the An example to use caches via GitHub Cache API: - uses: docker/setup-buildx-action@v2
- uses: docker/build-push-action@v3
with:
tags: test-image:latest
push: false
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
- uses: addnab/docker-run-action@v3
with:
image: test-image:latest
run: echo "hello world" Notices:
|
Thanks @envzhu — this was v helpful |
Hi, thanks for your great work on this, very helpful!
I was wondering what would be the best strategy to cache the docker image used by this action...would it be something related with using the cache action https://github.com/actions/cache? but how should we use it in combination with your action?
I also checked this thread: https://stackoverflow.com/questions/66421411/how-to-run-cached-docker-image-in-github-action, which gives a glimpse but I suppose your action would need to be modified for this...
The text was updated successfully, but these errors were encountered: