mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-12 22:47:09 +08:00
docs: fix cache command examples
Signed-off-by: David Karlsson <david.karlsson@docker.com>
This commit is contained in:
16
docs/guides/cache/gha.md
vendored
16
docs/guides/cache/gha.md
vendored
@ -26,9 +26,9 @@ inside your GitHub action pipelines, as long as your use case falls within the
|
||||
## Synopsis
|
||||
|
||||
```console
|
||||
$ docker buildx build . --push -t <registry>/<image> \
|
||||
$ docker buildx build --push -t <registry>/<image> \
|
||||
--cache-to type=gha[,parameters...] \
|
||||
--cache-from type=gha[,parameters...]
|
||||
--cache-from type=gha[,parameters...] .
|
||||
```
|
||||
|
||||
The following table describes the available CSV parameters that you can pass to
|
||||
@ -67,12 +67,12 @@ example, the cache is set to a combination of the branch name and the image
|
||||
name, to ensure each branch gets its own cache):
|
||||
|
||||
```console
|
||||
$ docker buildx build . --push -t <registry>/<image> \
|
||||
--cache-to type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image
|
||||
--cache-from type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image
|
||||
$ docker buildx build . --push -t <registry>/<image2> \
|
||||
--cache-to type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image2
|
||||
--cache-from type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image2
|
||||
$ docker buildx build --push -t <registry>/<image> \
|
||||
--cache-to type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image \
|
||||
--cache-from type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image .
|
||||
$ docker buildx build --push -t <registry>/<image2> \
|
||||
--cache-to type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image2 \
|
||||
--cache-from type=gha,url=...,token=...,scope=$GITHUB_REF_NAME-image2 .
|
||||
```
|
||||
|
||||
GitHub's
|
||||
|
Reference in New Issue
Block a user