Skip to content

Merge pull request #486 from hedgedoc/renovate/docker.io-library-node… #321

Merge pull request #486 from hedgedoc/renovate/docker.io-library-node…

Merge pull request #486 from hedgedoc/renovate/docker.io-library-node… #321

Workflow file for this run

name: Container release
on:
push:
branches: [main, master]
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
strategy:
matrix:
base: [debian, alpine]
env:
# renovate: datasource=github-tags depName=hedgedoc/hedgedoc versioning=semver
HEDGEDOC_VERSION: 1.9.9
HEDGEDOC_IMAGE: quay.io/hedgedoc/hedgedoc
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Set up QEMU
uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@988b5a0280414f521da01fcc63a27aeeb4b104db # v3
- name: Login to docker registry
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3
with:
registry: quay.io
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Set flavor tags
run: echo "TAGS=$HEDGEDOC_IMAGE:${{ env.HEDGEDOC_VERSION }}-${{ matrix.base }},$HEDGEDOC_IMAGE:${{ matrix.base }}" >> $GITHUB_ENV
- name: Set main flavor tags
if: ${{ matrix.base == 'debian' }}
run: echo "TAGS=$TAGS,$HEDGEDOC_IMAGE:${{ env.HEDGEDOC_VERSION }},$HEDGEDOC_IMAGE:latest" >> $GITHUB_ENV
- name: Build and push image
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6
with:
context: .
file: ./${{ matrix.base }}/Dockerfile
build-args: |
VERSION=${{ env.HEDGEDOC_VERSION }}
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ env.TAGS }}