From 71c1221134cf04e494138c5214a1143485d5cf54 Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Mon, 15 May 2023 15:13:50 +0200 Subject: [PATCH] Build docker image with and without influxdb --- .github/workflows/dockerimage.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/dockerimage.yml b/.github/workflows/dockerimage.yml index 2a80399..b40d0e7 100644 --- a/.github/workflows/dockerimage.yml +++ b/.github/workflows/dockerimage.yml @@ -16,6 +16,9 @@ jobs: permissions: contents: read packages: write + strategy: + matrix: + with_influxdb: ["no", "yes"] steps: - name: Checkout @@ -28,6 +31,8 @@ jobs: # list of Docker images to use as base name for tags images: | ghcr.io/${{ github.repository }} + flavor: | + suffix=${{ matrix.with_influxdb == 'yes' && '-with-influxdb' || '' }}, onlatest=true - name: Set up QEMU uses: docker/setup-qemu-action@v2 @@ -47,6 +52,8 @@ jobs: uses: docker/build-push-action@v4 with: context: . + build-args: | + with_influxdb=${{ matrix.with_influx_db }} platforms: linux/amd64,linux/386,linux/arm64,linux/arm push: ${{ github.event_name != 'pull_request' }} tags: ${{ steps.meta.outputs.tags }}