Skip to content

Docker

Docker #1

name: Docker
on:
workflow_run:
workflows: ["CI"]
branches: ["main"]
types: ["completed"]
jobs:
docker-release:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
strategy:
matrix:
include:
- build_args: |
BIN_NAME=broker-2-http
app_name: broker-2-http
- build_args: |
BIN_NAME=http-2-broker
app_name: http-2-broker
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Log into registry ghcr.io
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push ${{ matrix.app_name }}
uses: docker/build-push-action@v6
with:
context: .
build-args: ${{ matrix.build_args }}
tags: |
ghcr.io/INTERSECT-SDK/broker-http-proxy/${{ matrix.app_name }}:latest
ghcr.io/INTERSECT-SDK/broker-http-proxy/${{ matrix.app_name }}:${{ github.sha }}
push: true