Skip to content

Build and deploy from branch. #49

Build and deploy from branch.

Build and deploy from branch. #49

name: Build, push and update
on:
workflow_dispatch:
inputs:
skip-unit-test:
type: boolean
required: true
description: Skip unit-test
jobs:
build_push_update:
runs-on: ubuntu-latest
environment: dev-cd
permissions:
id-token: write
packages: write
contents: write
steps:
#
# Checkout the source code.
#
- name: Checkout the source code
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab
with:
token: ${{ secrets.GIT_PAT }}
fetch-depth: 0
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Build the app image
uses: docker/build-push-action@v4
with:
push: true
context: .
file: src/main/docker/Dockerfile.multistage
platforms: linux/amd64
tags: ghcr.io/${{ github.repository }}:${{ github.head_ref || github.ref_name }}
secrets: |
"gh_user=${{ secrets.GIT_USER }}"
"gh_token=${{ secrets.GIT_PAT }}"