Skip to content

Commit

Permalink
chore: use docker/metadata-action
Browse files Browse the repository at this point in the history
  • Loading branch information
vittee committed May 24, 2024
1 parent 13d0006 commit edbf954
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions .github/workflows/radio-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,19 @@ jobs:
with:
submodules: recursive

- name: Get image repository short commit
id: version
run: |
echo "SHORT_SHA=$(echo $GITHUB_SHA | cut -c 1-8)" >> $GITHUB_OUTPUT
# - name: Get image repository short commit
# id: version
# run: |
# echo "SHORT_SHA=$(echo $GITHUB_SHA | cut -c 1-8)" >> $GITHUB_OUTPUT

- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
images: |
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=sha
- name: Log in to the Container registry
uses: docker/login-action@v3
Expand All @@ -41,4 +50,6 @@ jobs:
context: .
file: ./packages/radio/docker/discord/Dockerfile
push: true
tags: "${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.SHORT_SHA }},${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest"
# tags: "${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.SHORT_SHA }},${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest"
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

0 comments on commit edbf954

Please sign in to comment.