Skip to content

Bump docker/setup-buildx-action from 2 to 3 #180

Bump docker/setup-buildx-action from 2 to 3

Bump docker/setup-buildx-action from 2 to 3 #180

Workflow file for this run

name: Docker PHP Images GitHub workflow
on:
pull_request:
branches:
- 'v5'
- 'v6'
push:
branches:
- 'v5'
- 'v6'
schedule:
- cron: '42 3 * * 0'
workflow_dispatch:
jobs:
build_test_maybe_release:
name: 'Build & test'
strategy:
matrix:
php_version: ['8.0', '8.1', '8.2']
platform: ['linux/amd64', 'linux/arm64']
variant: ['apache', 'cli', 'fpm']
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Checkout
uses: actions/checkout@v4
- name: Build and test
run: |
PHP_VERSION="${{ matrix.php_version }}" BRANCH="${{ github.ref_name }}" VARIANT="${{ matrix.variant }}" OWNER="${{ secrets.DOCKERHUB_USERNAME }}" PLATFORM="${{ matrix.platform }}" ./build-and-test.sh
docker images | grep ${OWNER}/php
- name: Login to DockerHub
# Merge ~ push.
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Release
# Merge ~ push.
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
run: |
PHP_VERSION="${{ matrix.php_version }}" BRANCH="${{ github.ref_name }}" VARIANT="${{ matrix.variant }}" OWNER="${{ secrets.DOCKERHUB_USERNAME }}" PLATFORM="${{ matrix.platform }}" ./push.sh
combine_archs:
name: 'Combine & release'
# Merge ~ push.
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
needs: [ build_test_maybe_release ]
strategy:
matrix:
php_version: ['8.0', '8.1', '8.2']
variant: ['apache', 'cli', 'fpm']
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Checkout
uses: actions/checkout@v3
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Create combined Manifest
run: PHP_VERSION="${{ matrix.php_version }}" BRANCH="${{ github.ref_name }}" VARIANT="${{ matrix.variant }}" OWNER="${{ secrets.DOCKERHUB_USERNAME }}" ./combine_archs.sh