Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,33 +1,21 @@
name: Build & Deploy to PROD
name: Publish Docker Image

on:
release:
types: [published]
branches: [main]

workflow_call:
inputs:
tag_name:
description: Docker image tag / Release tag
required: true
type: string
target_commitish:
description: Branch to build from
required: true
type: string

jobs:
deploy:
if: ${{ inputs.target_commitish == 'main' || github.event.release.target_commitish == 'main' }}
name: Build & Deploy
name: Build & Push Docker Image
runs-on: ubuntu-latest

permissions:
contents: read
packages: write

env:
RELEASE_TAG: ${{ inputs.tag_name || github.event.release.tag_name }}
RELEASE_TAG: ${{ github.event.release.tag_name }}

steps:
- name: Checkout code
Expand All @@ -49,15 +37,15 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Generate Docker metadata
- name: Generate Docker Metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=semver,pattern={{version}},value=${{ env.RELEASE_TAG }}

- name: Build & Push Docker image
- name: Build & Push Docker Image
uses: docker/build-push-action@v5
with:
context: .
Expand Down
33 changes: 0 additions & 33 deletions .github/workflows/dispatch-release.yml

This file was deleted.