cache-image input to enable/disable caching of binfmt image#130
cache-image input to enable/disable caching of binfmt image#130tonistiigi merged 2 commits intodocker:masterfrom
Conversation
490df49 to
67290d2
Compare
tonistiigi
left a comment
There was a problem hiding this comment.
How does this cache get invalidated?
Signed-off-by: CrazyMax <[email protected]>
Signed-off-by: CrazyMax <[email protected]>
9d2e9ac to
c3bed4e
Compare
|
Why is this also storing it in the tool cache? This is not a tool, and this behavior is not consistent with the use of the tool cache, nor used in any other of the docker actions |
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 3.2.0 to 3.3.0. Release notes *Sourced from [docker/setup-qemu-action's releases](https://github.com/docker/setup-qemu-action/releases).* > v3.3.0 > ------ > > * Add `cache-image` input to enable/disable caching of binfmt image by [`@crazy-max`](https://github.com/crazy-max) in [docker/setup-qemu-action#130](https://redirect.github.com/docker/setup-qemu-action/pull/130) > * Bump `@actions/core` from 1.10.1 to 1.11.1 in [docker/setup-qemu-action#172](https://redirect.github.com/docker/setup-qemu-action/pull/172) > * Bump `@docker/actions-toolkit` from 0.35.0 to 0.49.0 in [docker/setup-qemu-action#187](https://redirect.github.com/docker/setup-qemu-action/pull/187) > * Bump cross-spawn from 7.0.3 to 7.0.6 in [docker/setup-qemu-action#182](https://redirect.github.com/docker/setup-qemu-action/pull/182) > * Bump path-to-regexp from 6.2.2 to 6.3.0 in [docker/setup-qemu-action#162](https://redirect.github.com/docker/setup-qemu-action/pull/162) > > **Full Changelog**: <docker/setup-qemu-action@v3.2.0...v3.3.0> Commits * [`53851d1`](docker/setup-qemu-action@53851d1) Merge pull request [#187](https://redirect.github.com/docker/setup-qemu-action/issues/187) from docker/dependabot/npm\_and\_yarn/docker/actions-to... * [`7066b90`](docker/setup-qemu-action@7066b90) chore: update generated content * [`7559081`](docker/setup-qemu-action@7559081) build(deps): bump `@docker/actions-toolkit` from 0.35.0 to 0.49.0 * [`08d11eb`](docker/setup-qemu-action@08d11eb) Merge pull request [#172](https://redirect.github.com/docker/setup-qemu-action/issues/172) from docker/dependabot/npm\_and\_yarn/actions/core-1.11.1 * [`e53506f`](docker/setup-qemu-action@e53506f) chore: update generated content * [`610b442`](docker/setup-qemu-action@610b442) build(deps): bump `@actions/core` from 1.10.1 to 1.11.1 * [`58a19f8`](docker/setup-qemu-action@58a19f8) Merge pull request [#182](https://redirect.github.com/docker/setup-qemu-action/issues/182) from docker/dependabot/npm\_and\_yarn/cross-spawn-7.0.6 * [`49a12c4`](docker/setup-qemu-action@49a12c4) Merge pull request [#180](https://redirect.github.com/docker/setup-qemu-action/issues/180) from docker/dependabot/github\_actions/codecov/codecov... * [`2b8ac83`](docker/setup-qemu-action@2b8ac83) ci: fix deprecated input for codecov-action * [`fdbeaac`](docker/setup-qemu-action@fdbeaac) Merge pull request [#130](https://redirect.github.com/docker/setup-qemu-action/issues/130) from crazy-max/cache-image * Additional commits viewable in [compare view](docker/setup-qemu-action@49b3bc8...53851d1) [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- Dependabot commands and options You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- disables caching the qemu image (docker/setup-qemu-action#130). There might be a lack of specificity in the cache key generated from the image tag (`docker.io/tonistiigi/binfmt:latest`): https://github.com/docker/actions-toolkit/blob/39e9b0e5c11efcb5cd80bca4f00eebf1695ecf59/src/docker/docker.ts#L132-L170 - allows running release CI via manual trigger on non-default branches without uploading artifacts (as a pre-release) to test-pypi.
|
Is there any output key added to skip pushing to the cache if it already exists? All actions seem to be throwing 409 warnings about matching caches.
|
Yes we should skip in this case I will take a look. |
After investigation it seems related to new cache service v2 that has been enabled in Feb, 11: actions/cache#1541 Looking at comment from maintainer it seems to be an issue on their side that will be fixed in few days: actions/cache#1541 (comment) Looks like they are going to remove this annotation that was not there before: But since Feb, 11: Fyi it makes sense to have this message if you're using |
Seems it has been fixed in actions/toolkit#1966 Will bring this in our actions-toolkit |
|
Thanks, that will fix the warning. But doesn't the underlying problem still deserve fixing, because it will always try to re-create the cache entry even if it was a cache hit? |


follow-up docker/actions-toolkit#200
related to #110
fixes #166
Tested through ci workflow
first run
setup-qemu-action saves image to hosted tool cache: https://github.com/docker/setup-qemu-action/actions/runs/9775565828/job/26986231861#step:3:113
And post cache to upload to GitHub Cache store: https://github.com/docker/setup-qemu-action/actions/runs/9775565828/job/26986231861#step:7:3
second run
download image from cache and load it: https://github.com/docker/setup-qemu-action/actions/runs/9775565828/job/26986391188#step:3:105
See cache entries as well: https://github.com/docker/setup-qemu-action/actions/caches