We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a95dbe4 commit 236f3faCopy full SHA for 236f3fa
.github/workflows/build-docker.yml
@@ -35,11 +35,20 @@ jobs:
35
username: ${{ github.actor }}
36
password: ${{ secrets.GITHUB_TOKEN }}
37
38
+ - name: Extract version from package.json
39
+ id: pkg
40
+ run: |
41
+ VERSION=$(jq -r '.version' package.json)
42
+ echo "version=$VERSION" >> "$GITHUB_OUTPUT"
43
+
44
- name: Extract metadata (tags, labels)
45
id: meta
46
uses: docker/metadata-action@v5
47
with:
48
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
49
+ tags: |
50
+ type=raw,value=${{ steps.pkg.outputs.version }}
51
+ type=raw,value=latest,enable={{is_default_branch}}
52
53
- name: Build and push
54
uses: docker/build-push-action@v6
0 commit comments