Merge pull request #70 from betadots/renovate/configure #71
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Build and publish a 🛢️ container | |
on: | |
push: | |
branches: | |
- 'main' | |
tags: | |
- '*' | |
workflow_dispatch: | |
jobs: | |
setup-matrix: | |
runs-on: ubuntu-latest | |
outputs: | |
matrix: ${{ steps.set-matrix.outputs.matrix }} | |
steps: | |
- name: Source checkout | |
uses: actions/checkout@v4 | |
- id: set-matrix | |
run: echo "matrix=$(jq -c . build_versions.json)" >> $GITHUB_OUTPUT | |
build-and-push-container: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
needs: setup-matrix | |
strategy: | |
matrix: ${{ fromJson(needs.setup-matrix.outputs.matrix) }} | |
steps: | |
- name: Build Puppet Development Container ${{ matrix.puppet_release }} | |
uses: voxpupuli/gha-build-and-publish-a-container@v2 | |
with: | |
registry_password: ${{ secrets.GITHUB_TOKEN }} | |
build_args: | | |
PUPPET_RELEASE=${{ matrix.puppet_release }} | |
PUPPET_VERSION=${{ matrix.puppet_version }} | |
TERRAFORM_VERSION=${{ matrix.terraform_version }} | |
PDK_VERSION=${{ matrix.pdk_version }} | |
BOLT_VERSION=${{ matrix.bolt_version }} | |
PUPPETDB_TERMINI_VERSION=${{ matrix.puppetdb_termini_version }} | |
# we can not yet build arm containers as pdk and bolt are not available for arm | |
# build_arch: linux/amd64,linux/arm64 | |
docker_username: ${{ vars.DOCKERHUB_USER }} | |
docker_password: ${{ secrets.DOCKERHUB_TOKEN }} | |
tags: | | |
ghcr.io/${{ github.repository }}:${{ github.ref_name }}-${{ matrix.puppet_release }} | |
ghcr.io/${{ github.repository }}:latest-${{ matrix.puppet_release }} | |
ghcr.io/${{ github.repository }}:latest | |
docker.io/${{ github.repository }}:${{ github.ref_name }}-${{ matrix.puppet_release }} | |
docker.io/${{ github.repository }}:latest-${{ matrix.puppet_release }} | |
docker.io/${{ github.repository }}:latest | |
- name: Update Docker Hub Description | |
uses: peter-evans/dockerhub-description@v4 | |
with: | |
username: ${{ vars.DOCKERHUB_USER }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} |