Skip to content

Building Docker Image #36

Building Docker Image

Building Docker Image #36

Workflow file for this run

name: Building Docker Image
on:
workflow_run:
workflows:
- Testing CI pipeline
types:
- completed
jobs:
docker-build:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- name: Setup docker buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build docker container
uses: docker/build-push-action@v5
with:
cache-from: type=gha
cache-to: type=gha,mode=max
tags: ghcr.io/it-rex-platform/template_microservice:latest
push: true