Update build_image.yml

This commit is contained in:
Linus Dietz
2023-06-19 11:52:25 +02:00
committed by GitHub
parent 666eda99d0
commit 1ed6035a54
+18
View File
@@ -43,9 +43,27 @@ jobs:
uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
- name: Docker meta
id: <meta_id> # you'll use this in the next step
uses: docker/metadata-action@v3
with:
# list of Docker images to use as base name for tags
images: |
<specify the image name>
# Docker tags based on the following events/attributes
tags: |
type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=sha
- name: Build and push
uses: docker/build-push-action@v2
with:
context: .
platforms: linux/amd64,linux/arm/v7
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.<meta_id>.outputs.tags }}
labels: ${{ steps.<meta_id>.outputs.labels }}