feat: image tag for releases

This commit is contained in:
Matthias 2024-10-31 19:25:51 +01:00
parent 59ac087b9d
commit 889ab1fe43

View File

@ -5,9 +5,8 @@ on:
branches: branches:
- main - main
- docker_container - docker_container
# pull_request: release:
# branches: types: [published]
# - main
workflow_dispatch: workflow_dispatch:
jobs: jobs:
@ -43,11 +42,14 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }} password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image - name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6 uses: docker/build-push-action@v6
with: with:
platforms: linux/amd64,linux/arm64,linux/arm/v7, platforms: linux/amd64,linux/arm64,linux/arm/v7
context: . context: .
push: true push: true
tags: | tags: |
freqtradeorg/frequi:latest ${{ github.ref == 'refs/heads/main' && 'freqtradeorg/frequi:latest' || '' }}
ghcr.io/freqtrade/frequi:latest ${{ github.ref == 'refs/heads/main' && 'ghcr.io/freqtrade/frequi:latest' || '' }}
${{ github.event_name == 'release' && github.event.release.tag_name != '' && format('freqtradeorg/frequi:{0}', github.event.release.tag_name) || '' }}
${{ github.event_name == 'release' && github.event.release.tag_name != '' && format('ghcr.io/freqtrade/frequi:{0}', github.event.release.tag_name) || '' }}