mirror of
https://github.com/docker/build-push-action.git
synced 2026-04-08 15:36:41 +00:00
fix test since secrets are not written to temp path anymore
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
This commit is contained in:
parent
c850e6994a
commit
919ac7bd7d
23
.github/workflows/ci.yml
vendored
23
.github/workflows/ci.yml
vendored
@ -445,6 +445,29 @@ jobs:
|
|||||||
MYSECRET=foo
|
MYSECRET=foo
|
||||||
INVALID_SECRET=
|
INVALID_SECRET=
|
||||||
|
|
||||||
|
secret-files:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4.0.0
|
||||||
|
with:
|
||||||
|
version: ${{ inputs.buildx-version || env.BUILDX_VERSION }}
|
||||||
|
driver-opts: |
|
||||||
|
image=${{ inputs.buildkit-image || env.BUILDKIT_IMAGE }}
|
||||||
|
-
|
||||||
|
name: Build
|
||||||
|
uses: ./
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
file: ./test/secret.Dockerfile
|
||||||
|
secret-files: |
|
||||||
|
MYSECRET=./test/secret.txt
|
||||||
|
INVALID_SECRET=
|
||||||
|
|
||||||
secret-envs:
|
secret-envs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
|
|||||||
@ -389,7 +389,7 @@ ccc`],
|
|||||||
'build',
|
'build',
|
||||||
'--file', './test/Dockerfile',
|
'--file', './test/Dockerfile',
|
||||||
'--iidfile', imageIDFilePath,
|
'--iidfile', imageIDFilePath,
|
||||||
'--secret', `id=MY_SECRET,src=${tmpName}`,
|
'--secret', `id=MY_SECRET,src=${path.join(fixturesDir, 'secret.txt')}`,
|
||||||
'--builder', 'builder-git-context-2',
|
'--builder', 'builder-git-context-2',
|
||||||
'--network', 'host',
|
'--network', 'host',
|
||||||
'--push',
|
'--push',
|
||||||
|
|||||||
1
test/secret.txt
Normal file
1
test/secret.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
foo
|
||||||
Loading…
Reference in New Issue
Block a user