Skip to content

major updates

major updates #2

Workflow file for this run

name: ci
on:
pull_request:
push:
branches:
- master
env:
IMAGE_NAME: mileschou/phalcon
PHALCON_VERSION: 5.3.1
jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 8
fail-fast: true
matrix:
php:
- 8.2
- 8.1
- "8.0"
- 7.4
variant:
- "" # cli
- -fpm
os:
- "" # debian-latest
- -alpine
env:
PHP_VARIANT: ${{ matrix.php }}${{ matrix.variant }}${{ matrix.os }}
steps:
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
-
name: Build
uses: docker/build-push-action@v5
with:
load: true
file: Dockerfile${{ matrix.os }}
build-args: |
PHP_VARIANT=${{ env.PHP_VARIANT }}
PHALCON_VERSION=${{ env.PHALCON_VERSION }}
tags: ${{ env.IMAGE_NAME }}:${{ env.PHP_VARIANT }}-tesing
-
name: Test
run: docker run --rm ${{ env.IMAGE_NAME }}:${{ env.PHP_VARIANT }}-tesing sh -c "php -v; php --ri phalcon | grep -i ^version"
-
name: Login
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
if: github.event_name != 'pull_request'
uses: docker/build-push-action@v5
with:
push: true
file: Dockerfile${{ matrix.os }}
build-args: |
PHP_VARIANT=${{ env.PHP_VARIANT }}
PHALCON_VERSION=${{ env.PHALCON_VERSION }}
platforms: linux/amd64,linux/arm64
tags: ${{ env.IMAGE_NAME }}:${{ env.PHP_VARIANT }}