Skip to content

Commit 382640a

Browse files
authored
Merge pull request #3 from codetent/harden
extract metadata using action
2 parents bcda9c7 + b819a4f commit 382640a

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/build-dev.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,18 @@ jobs:
1818
registry: ghcr.io
1919
username: ${{ github.actor }}
2020
password: ${{ secrets.GITHUB_TOKEN }}
21+
- name: Extract metadata for image
22+
id: meta
23+
uses: docker/metadata-action@v5
24+
with:
25+
images: ghcr.io/${{ github.repository }}/dev
26+
tags: |
27+
type=sha
2128
- name: Build & push image
2229
uses: docker/build-push-action@v6
2330
with:
2431
context: .
2532
file: .devcontainer/Dockerfile
26-
tags: ghcr.io/${{ github.repository }}/dev:${{ github.sha }}
33+
tags: ${{ steps.meta.outputs.tags }}
34+
labels: ${{ steps.meta.outputs.labels }}
2735
push: true

0 commit comments

Comments
 (0)