3
0
Fork 0
mirror of https://gitea.com/docker/build-push-action.git synced 2024-11-22 09:29:38 +01:00

Update CI workflow

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax 2020-09-22 20:53:40 +02:00
parent 86856eb412
commit 32351da9d7
No known key found for this signature in database
GPG key ID: 3248E46B6BB8C7F7

View file

@ -11,11 +11,53 @@ on:
jobs: jobs:
git-context: git-context:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: services:
fail-fast: false registry:
matrix: image: registry:2
buildx-version: ports:
- latest - 5000:5000
steps:
-
name: Checkout
uses: actions/checkout@v2.3.2
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all
-
name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
with:
version: latest
driver-opts: network=host
-
name: Build and push
id: docker_build
uses: ./
with:
file: ./test/Dockerfile
builder: ${{ steps.buildx.outputs.name }}
platforms: linux/amd64,linux/arm64
push: true
tags: |
localhost:5000/name/app:latest
localhost:5000/name/app:1.0.0
-
name: Inspect
run: |
docker buildx imagetools inspect localhost:5000/name/app:1.0.0
-
name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
-
name: Dump context
if: always()
uses: crazy-max/ghaction-dump-context@v1
git-context-secret:
runs-on: ubuntu-latest
services: services:
registry: registry:
image: registry:2 image: registry:2
@ -50,7 +92,7 @@ jobs:
localhost:5000/name/app:latest localhost:5000/name/app:latest
localhost:5000/name/app:1.0.0 localhost:5000/name/app:1.0.0
secrets: | secrets: |
GIT_AUTH_TOKEN=${{ github.token }} GIT_AUTH_TOKEN=01234567890abcdefgh
- -
name: Inspect name: Inspect
run: | run: |