updates #519
This file contains hidden or 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: | |
| - master | |
| schedule: | |
| - cron: 0 4 * * SUN | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| packages: write | |
| jobs: | |
| generic: | |
| name: Build dependency-free Docker images | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-qemu-action@v3 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: default | |
| rust: | |
| name: Build Rust-infected images | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-qemu-action@v3 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: rust-build | |
| erlang-multiarch: | |
| name: Build Erlang ${{ matrix.versions }} on ${{ matrix.runners }} | |
| runs-on: ${{ matrix.runners }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| versions: | |
| - "26.2.5.17" | |
| - "27.3.4.8" | |
| - "28.3.1" | |
| runners: | |
| - "ubuntu-24.04" | |
| - "ubuntu-24.04-arm" | |
| env: | |
| RUNNER: ${{ matrix.runners }} | |
| VERSION: ${{ matrix.versions }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: erlang | |
| erlang-merge: | |
| name: Merge Erlang ${{ matrix.major }} image | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - erlang-multiarch | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| major: | |
| - "26" | |
| - "27" | |
| - "28" | |
| steps: | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - run: | | |
| docker buildx imagetools create \ | |
| -t 1maa/erlang:${{ matrix.major }}-alpine \ | |
| ghcr.io/1ma/erlang:${{ matrix.major }}-ubuntu-24.04 \ | |
| ghcr.io/1ma/erlang:${{ matrix.major }}-ubuntu-24.04-arm | |
| php-multiarch: | |
| name: Build PHP ${{ matrix.versions }} on ${{ matrix.runners }} | |
| runs-on: ${{ matrix.runners }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| versions: | |
| - "8.2.30" | |
| - "8.3.30" | |
| - "8.4.18" | |
| - "8.5.3" | |
| runners: | |
| - "ubuntu-24.04" | |
| - "ubuntu-24.04-arm" | |
| env: | |
| RUNNER: ${{ matrix.runners }} | |
| VERSION: ${{ matrix.versions }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: php | |
| php-merge: | |
| name: Merge PHP ${{ matrix.versions }} image | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - php-multiarch | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| versions: | |
| - "8.2" | |
| - "8.3" | |
| - "8.4" | |
| - "8.5" | |
| steps: | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - run: | | |
| docker buildx imagetools create \ | |
| -t 1maa/php:${{ matrix.versions }} \ | |
| ghcr.io/1ma/php:${{ matrix.versions }}-ubuntu-24.04 \ | |
| ghcr.io/1ma/php:${{ matrix.versions }}-ubuntu-24.04-arm | |
| postgres-multiarch: | |
| name: Build Postgres ${{ matrix.versions }} on ${{ matrix.runners }} | |
| runs-on: ${{ matrix.runners }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| versions: | |
| - "13.23" | |
| - "14.21" | |
| - "15.16" | |
| - "16.12" | |
| - "17.8" | |
| - "18.2" | |
| runners: | |
| - "ubuntu-24.04" | |
| - "ubuntu-24.04-arm" | |
| env: | |
| RUNNER: ${{ matrix.runners }} | |
| VERSION: ${{ matrix.versions }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: postgres | |
| postgres-merge: | |
| name: Merge Postgres ${{ matrix.major }} image | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - postgres-multiarch | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| major: | |
| - "13" | |
| - "14" | |
| - "15" | |
| - "16" | |
| - "17" | |
| - "18" | |
| steps: | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - run: | | |
| docker buildx imagetools create \ | |
| -t 1maa/postgres:${{ matrix.major }}-alpine \ | |
| ghcr.io/1ma/postgres:${{ matrix.major }}-ubuntu-24.04 \ | |
| ghcr.io/1ma/postgres:${{ matrix.major }}-ubuntu-24.04-arm | |
| sqlite-multiarch: | |
| name: Build SQLite on ${{ matrix.runners }} | |
| runs-on: ${{ matrix.runners }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| runners: | |
| - "ubuntu-24.04" | |
| - "ubuntu-24.04-arm" | |
| env: | |
| RUNNER: ${{ matrix.runners }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: docker/bake-action@v6 | |
| with: | |
| provenance: false | |
| push: true | |
| sbom: false | |
| targets: sqlite | |
| sqlite-merge: | |
| name: Merge SQLite image | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - sqlite-multiarch | |
| steps: | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| username: 1maa | |
| password: ${{ secrets.DOCKER_HUB_PASS }} | |
| - run: | | |
| docker buildx imagetools create \ | |
| -t 1maa/sqlite:latest \ | |
| ghcr.io/1ma/sqlite:ubuntu-24.04 \ | |
| ghcr.io/1ma/sqlite:ubuntu-24.04-arm | |
| ghcr-cleanup: | |
| name: Cleanup stale GHCR images | |
| runs-on: ubuntu-24.04 | |
| needs: | |
| - erlang-merge | |
| - php-merge | |
| - postgres-merge | |
| - sqlite-merge | |
| steps: | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: actions/delete-package-versions@v5 | |
| with: | |
| package-name: erlang | |
| package-type: container | |
| delete-only-untagged-versions: true | |
| min-versions-to-keep: 0 | |
| - uses: actions/delete-package-versions@v5 | |
| with: | |
| package-name: php | |
| package-type: container | |
| delete-only-untagged-versions: true | |
| min-versions-to-keep: 0 | |
| - uses: actions/delete-package-versions@v5 | |
| with: | |
| package-name: postgres | |
| package-type: container | |
| delete-only-untagged-versions: true | |
| min-versions-to-keep: 0 | |
| - uses: actions/delete-package-versions@v5 | |
| with: | |
| package-name: sqlite | |
| package-type: container | |
| delete-only-untagged-versions: true | |
| min-versions-to-keep: 0 |