Add test for creating packages and specs #591
Workflow file for this run
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 Docker Images | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- analytics/** | |
- images/** | |
- .github/workflows/custom_docker_builds.yml | |
pull_request: | |
paths: | |
- analytics/** | |
- images/** | |
- .github/workflows/custom_docker_builds.yml | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- docker-image: ./images/gh-gl-sync | |
image-tags: ghcr.io/spack/ci-bridge:0.0.43 | |
- docker-image: ./images/ci-key-clear | |
image-tags: ghcr.io/spack/ci-key-clear:0.0.2 | |
- docker-image: ./images/gitlab-stuckpods | |
image-tags: ghcr.io/spack/stuckpods:0.0.1 | |
- docker-image: ./images/gitlab-clear-pipelines | |
image-tags: ghcr.io/spack/gitlab-clear-pipelines:0.0.1 | |
- docker-image: ./images/gitlab-delete-stale-branches | |
image-tags: ghcr.io/spack/gitlab-delete-stale-branches:0.0.1 | |
- docker-image: ./images/gitlab-skipped-pipelines | |
image-tags: ghcr.io/spack/gitlab-skipped-pipelines:0.0.2 | |
- docker-image: ./images/notary | |
image-tags: ghcr.io/spack/notary:latest | |
- docker-image: ./images/python-aws-bash | |
image-tags: ghcr.io/spack/python-aws-bash:0.0.2 | |
- docker-image: ./images/snapshot-release-tags | |
image-tags: ghcr.io/spack/snapshot-release-tags:0.0.4 | |
- docker-image: ./images/cache-indexer | |
image-tags: ghcr.io/spack/cache-indexer:0.0.3 | |
- docker-image: ./analytics | |
image-tags: ghcr.io/spack/django:0.3.28 | |
- docker-image: ./images/ci-prune-buildcache | |
image-tags: ghcr.io/spack/ci-prune-buildcache:0.0.4 | |
- docker-image: ./images/protected-publish | |
image-tags: ghcr.io/spack/protected-publish:0.0.1 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@1d96c772d19495a3b5c517cd2bc0cb401ea0529f # v4.1.3 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@5927c834f5b4fdf503fca6f4c7eccda82949e1ee # v3.1.0 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@4fd812986e6c8c2a69e18311145f9371337f27d4 # v3.4.0 | |
- name: Log in to the Container registry | |
uses: docker/login-action@0d4c9c5ea7693da7b068278f7b52bda2a190a446 # v3.2.0 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build ${{ (github.ref == 'refs/heads/main' && 'and push ') || '' }}${{ matrix.docker-image }} | |
id: docker-build-push | |
uses: docker/build-push-action@a254f8ca60a858f3136a2f1f23a60969f2c402dd # v6.4.0 | |
with: | |
context: ${{ matrix.docker-image }} | |
file: ${{ matrix.docker-image }}/Dockerfile | |
push: ${{ github.ref == 'refs/heads/main' }} # only publish image on push to main | |
tags: ${{ matrix.image-tags }} | |
platforms: linux/amd64,linux/arm64 | |
- name: Image digest | |
run: echo ${{ steps.docker-build-push.outputs.digest }} |