Skip to content

Merge 'release/v8.2.0' into master #41

Merge 'release/v8.2.0' into master

Merge 'release/v8.2.0' into master #41

Workflow file for this run

### This workflow setup instance then build and push images ###
name: Multi-arch build
on:
push:
tags:
- "v*"
jobs:
prepare-build:
name: "Prepare build"
runs-on: ubuntu-latest
outputs:
sourceTag: ${{ steps.prepare.outputs.sourceTag }}
dsHash: ${{ steps.prepare.outputs.dsHash }}
steps:
- name: prepare-build
id: prepare
run: |
echo "sourceTag=${GITHUB_REF#refs/tags/}" >> "$GITHUB_OUTPUT"
echo "dsHash=$(echo -n "$(date +'%Y.%m.%d-%H%M')" | md5sum | awk '{print $1}')" >> "$GITHUB_OUTPUT"
build:
name: "${{ matrix.name }} ${{ matrix.edition }}"
runs-on: ubuntu-latest
needs: [prepare-build]
strategy:
fail-fast: false
matrix:
name: ["Build Docs"]
dockerfile: ["Dockerfile"]
edition: [ "", "-ee", "-de"]
images: [ "proxy docservice converter" ]
include:
- edition: "-de"
name: "Build Docs non-plugins"
dockerfile: "Dockerfile.noplugins"
images: "proxy docservice converter"
postfix: "-noplugins"
- edition: ""
name: "Build utils"
dockerfile: "Dockerfile"
images: "example utils"
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
- name: "Build Docs${{ matrix.edition }}"
env:
DS_VERSION_HASH: ${{ needs.prepare-build.outputs.dsHash }}
SOURCE_TAG: ${{ needs.prepare-build.outputs.sourceTag }}
NOPLUG_POSTFIX: ${{ matrix.postfix }}
DOCKERFILE: ${{ matrix.dockerfile }}
run: |
: ${DS_VERSION_HASH:?Should be set!}
DS_VERSION_HASH=${DS_VERSION_HASH} \
DOCKER_TAG=$(echo ${SOURCE_TAG} | sed 's/^.//') \
PRODUCT_EDITION=${{ matrix.edition }} \
TAG=$DOCKER_TAG \
docker buildx bake \
-f docker-bake.hcl ${{ matrix.images }} \
--push