Skip to content

edge-build

edge-build #248

Workflow file for this run

name: 'release'
on:
release:
types: [ published ]
repository_dispatch:
types: edge-build
workflow_dispatch:
inputs:
edge_build:
description: Edge build
default: 'true'
type: string
jobs:
test:
uses: coupergateway/couper-oidc-gateway/.github/workflows/test.yaml@master
build:
name: build container image
needs: test
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: checkout
uses: actions/checkout@v2
- name: Docker meta
id: meta
uses: docker/metadata-action@v3
with:
images: coupergateway/couper-oidc-gateway
tags: |
type=semver,pattern={{major}}.{{minor}}.{{patch}}
type=semver,pattern={{major}}.{{minor}}
type=edge,event=branch
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Build and push docker image with tag
if: ${{ github.event.client_payload.version != 'edge' && github.event.inputs.edge_build != 'true' }}
uses: docker/build-push-action@v2
with:
context: .
platforms: linux/amd64,linux/arm64
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ steps.meta.outputs.tags }}
push: true
- name: Build and push docker edge image
if: ${{ github.event.client_payload.version == 'edge' || github.event.inputs.edge_build == 'true' }}
uses: docker/build-push-action@v2
with:
context: .
platforms: linux/amd64,linux/arm64
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ steps.meta.outputs.tags }}
push: true
build-args: |
COUPER_VERSION=${{ github.event.client_payload.version || 'edge' }}
- name: Docker Hub Description
uses: peter-evans/dockerhub-description@v2
with:
readme-filepath: './README.md'
username: '${{ secrets.DOCKER_USERNAME }}'
password: '${{ secrets.DOCKER_PASSWORD }}'
repository: coupergateway/couper-oidc-gateway