Skip to content

Commit

Permalink
Merge pull request #2675 from dvdksn/run-mount-secret-env
Browse files Browse the repository at this point in the history
docs: update run mount secrets examples using env
  • Loading branch information
crazy-max authored Sep 5, 2024
2 parents ecfe98d + 479177e commit db11785
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/bake-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -871,8 +871,8 @@ This lets you [mount the secret][run_mount_secret] in your Dockerfile.
```dockerfile
RUN --mount=type=secret,id=aws,target=/root/.aws/credentials \
aws cloudfront create-invalidation ...
RUN --mount=type=secret,id=KUBECONFIG \
KUBECONFIG=$(cat /run/secrets/KUBECONFIG) helm upgrade --install
RUN --mount=type=secret,id=KUBECONFIG,env=KUBECONFIG \
helm upgrade --install
```

### `target.shm-size`
Expand Down
4 changes: 2 additions & 2 deletions docs/reference/buildx_build.md
Original file line number Diff line number Diff line change
Expand Up @@ -947,8 +947,8 @@ Attribute keys:
# syntax=docker/dockerfile:1
FROM node:alpine
RUN --mount=type=bind,target=. \
--mount=type=secret,id=SECRET_TOKEN \
SECRET_TOKEN=$(cat /run/secrets/SECRET_TOKEN) yarn run test
--mount=type=secret,id=SECRET_TOKEN,env=SECRET_TOKEN \
yarn run test
```

```console
Expand Down

0 comments on commit db11785

Please sign in to comment.