File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -2,9 +2,10 @@ name: Build and push Docker images
22
33on :
44 push :
5- branches : [ main ]
6- pull_request :
7- branches : [ main ]
5+ branches :
6+ - main
7+ tags :
8+ - " v*.*.*"
89 workflow_dispatch :
910
1011env :
6162 uses : docker/metadata-action@v5
6263 with :
6364 images : ${{ matrix.image }}
65+ tags : |
66+ type=ref,event=branch
67+ type=semver,pattern={{version}}
68+ type=semver,pattern={{major}}.{{minor}}
69+ type=semver,pattern={{major}}
70+ type=sha
6471
6572 - name : Build and push ${{ matrix.service }}
6673 uses : docker/build-push-action@v6
6976 context : .
7077 file : ${{ matrix.dockerfile }}
7178 push : true
72- tags : |
73- ${{ steps.meta.outputs.tags }}
74- ${{ matrix.image }}:latest
79+ tags : ${{ steps.meta.outputs.tags }}
7580 labels : ${{ steps.meta.outputs.labels }}
7681 cache-from : type=local,src=/tmp/.buildx-cache
7782 cache-to : type=local,dest=/tmp/.buildx-cache,mode=max
You can’t perform that action at this time.
0 commit comments