Open ad-m opened 5 years ago
See ad-m/github-push-action#19 too.
@joshmgross commented 5 minutes ago:
@ad-m I think it's fine to leave that in @actions/toolkit, as it's a general improvement to Docker actions. If the recommended step is to just cache before using every docker action, then that might be better if done by default.
Azure has recently released Teleport for images from Azure Container Registry ( https://stevelasker.blog/2019/10/29/azure-container-registry-teleportation/ ). The concept based on the use of SMB, which allows you to read only the necessary parts of layers without full transfer is very interesting, because it can give a very quick start in this use case. However, I suppose the Azure permissions model may still be too limited to direct integration, despite recent development of Azure in that area.
Now, we can pull a docker image from the Docker Hub or the GitHub Package Registry to skip a build step. But it is better the actions runner can cache a docker image with a built-in cache feature, not this cache action.
We are discussing at #37 that is focusing the Docker CLI, not a Docker action. We want to run a docker action with uses:
key and cache it like the actions beta v1.
We can skip a docker action build step like the following as a current workaround:
- uses: peaceiris/actions-gh-pages@v2
+ uses: docker://peaceiris/gh-pages:v2
(Edit: Now, this action migrated to a TypeScript Action) GitHub Actions for GitHub Pages
Although, we cannot verify those images are trusted. I hope that we can build a docker action and cache it on the GitHub Actions runner.
Any news?
I've tried using the docker save/load strategy but it does not work when the Dockerfile has a COPY/ADD command because the SHA produced is always different, I'm not sure why that happens, I've tried both with Github managed runners and self-hosted. Self-hosted works if I don't run docker system prune
which makes sense I think.
+1
This issue is stale because it has been open for 200 days with no activity. Leave a comment to avoid closing this issue in 5 days.
I see this issue is stale and in danger of being closed. I think this is a much needed feature that needs to be added.
This issue is stale because it has been open for 200 days with no activity. Leave a comment to avoid closing this issue in 5 days.
Still relevant.
Describe the enhancement
In my opinion, in the case of Docker actions, in many cases it is worthwhile to provide the cache for actions build. At least for published in the marketplace, it is possible to pre-build them by GitHub Actions and store as cache.
Currently, Docker actions are built multiple times as the first step of all builds, which is extremely inefficient for complex Docker actions.
Code Snippet This is due to the way the GitHub Actions worker works.
Additional information
The issue actions/toolkit#47 has been closed indicating a reference to
@actions/cache
, which however is limited to user data cache only. In this case, we do not have user data, but public actions, and the process is not controlled by the user at this stage (yet).