Skip to content

Publish frontend image to GHCR #14

Publish frontend image to GHCR

Publish frontend image to GHCR #14

name: Publish frontend image to GHCR
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
workflow_dispatch:
inputs:
tag:
description: 'Tag to publish'
required: true
default: 'latest'
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
name: Checkout
- uses: docker/login-action@v2
name: Login to GHCR
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- run: |
export FRONTEND_REF="$(tr '[:upper:]' '[:lower:]' <<<"${FRONTEND_REF}")"
docker buildx create --use
docker buildx bake --push \
--set frontend.platform=linux/amd64,linux/arm64 \
frontend
env:
FRONTEND_REF: ghcr.io/${{ github.repository }}/frontend:${{ github.event.inputs.tag }}