mirror of
https://gitea.com/docker/build-push-action.git
synced 2024-11-25 19:09:40 +01:00
Check digests
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
parent
ecc23e5785
commit
499091e46b
1 changed files with 10 additions and 0 deletions
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
|
@ -221,6 +221,8 @@ jobs:
|
||||||
|
|
||||||
github-cache-first:
|
github-cache-first:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
outputs:
|
||||||
|
digest: ${{ steps.docker_build.outputs.digest }}
|
||||||
services:
|
services:
|
||||||
registry:
|
registry:
|
||||||
image: registry:2
|
image: registry:2
|
||||||
|
@ -334,6 +336,14 @@ jobs:
|
||||||
-
|
-
|
||||||
name: Image digest
|
name: Image digest
|
||||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||||
|
-
|
||||||
|
name: Check digests
|
||||||
|
run: |
|
||||||
|
echo Compare "${{ needs.github-cache-first.outputs.digest }}" with "${{ steps.docker_build.outputs.digest }}"
|
||||||
|
if [ "${{ needs.github-cache-first.outputs.digest }}" != "${{ steps.docker_build.outputs.digest }}" ]; then
|
||||||
|
echo "::error::Digests should be identical"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
-
|
-
|
||||||
name: Cache hit
|
name: Cache hit
|
||||||
run: echo ${{ steps.cache.outputs.cache-hit }}
|
run: echo ${{ steps.cache.outputs.cache-hit }}
|
||||||
|
|
Loading…
Reference in a new issue