Skip to content

updated example filename #265

updated example filename

updated example filename #265

Workflow file for this run

on:
push: {}
workflow_dispatch: {}
jobs:
generate-matrix:
name: Generate build matrix
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- id: set-matrix
run: echo "::set-output name=matrix::$(./.github/workflows/generate-image-build-matrix images/*)"
build-and-push-arena-images:
needs: [generate-matrix]
runs-on: ubuntu-latest
if: ${{ needs.generate-matrix.outputs.matrix != '[]' }}
strategy:
fail-fast: true
matrix:
include: ${{ fromJson(needs.generate-matrix.outputs.matrix) }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Login to GHCR
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
registry: docker.io
username: diambrabot
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to Quay
uses: docker/login-action@v2
with:
registry: quay.io
username: diambra+github
password: ${{ secrets.QUAY_TOKEN }}
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: |
ghcr.io/diambra/arena-${{ matrix.name }}
docker.io/diambra/arena-${{ matrix.name }}
quay.io/diambra/arena-${{ matrix.name }}
tags: |
type=ref,event=branch
type=semver,pattern=v{{version}}
type=semver,pattern=v{{major}}.{{minor}}
type=raw,value=latest,enable={{is_default_branch}}
- name: Build and push arena ${{ matrix.dir }}
uses: docker/build-push-action@v3
with:
context: .
file: ${{ matrix.dir }}/Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: ${{ matrix.build_args }}