Update build.yml

This commit is contained in:
JB
2023-09-28 23:10:59 +01:00
committed by GitHub
parent 2f94751220
commit c6297ee9e3

View File

@@ -46,14 +46,14 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
- name: Metadata
id: gen_tags
id: tags
run: |
if [[ $GITHUB_REF == 'refs/tags/'* ]]; then
TAGS='["mochimqtt/server:latest","mochimqtt/server:'${GITHUB_REF/refs\/tags\//}'"]'
else
TAGS='["mochimqtt/server:latest"]'
fi
echo '::set-output name=tags::'$TAGS
echo "name=tags" >> $TAGS
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
@@ -67,4 +67,4 @@ jobs:
context: .
file: ./Dockerfile
push: true
tags: ${{ fromJson(steps.gen_tags.outputs.tags) }}
tags: ${{ steps.tags.outputs.tags }}