Build and push container (GHCR / Dockerhub) #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'Build and push container (GHCR / Dockerhub)' | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
inputs: | |
TAG_NAME: | |
description: 'Release Version Tag (0.0.0)' | |
required: true | |
permissions: | |
actions: write | |
packages: write | |
jobs: | |
node: | |
name: 'Build & Publish Container' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/[email protected] | |
with: | |
ref: ${{ github.ref }} | |
- name: Update Package to Release version | |
uses: technote-space/[email protected] | |
- name: Log in to the Container registry | |
uses: docker/[email protected] | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and push to GHCR | |
uses: docker/[email protected] | |
with: | |
platforms: linux/amd64 | |
file: ./Dockerfile | |
push: true | |
tags: | | |
ghcr.io/qxip/speech2hep:latest | |
ghcr.io/qxip/speech2hep:${{ github.event.inputs.TAG_NAME || github.event.release.tag_name }} | |
labels: | | |
dev.speech2hep.image.title=speech2hep | |
dev.speech2hep.image.type=nodejs | |
dev.speech2hep.image.version={{github.event.inputs.TAG_NAME || github.event.release.tag_name }} |