Test Docker image build on pull-requests
This commit is contained in:
parent
4c982294df
commit
9b03b50172
|
|
@ -5,8 +5,24 @@ on:
|
|||
push:
|
||||
tags:
|
||||
- 'v*.*.*'
|
||||
pull_request:
|
||||
branches: [ main ]
|
||||
jobs:
|
||||
test-image-build:
|
||||
if: github.event.pull_request
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
- name: Build image
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: .
|
||||
file: Dockerfile
|
||||
push: false
|
||||
|
||||
multiplatform-build:
|
||||
if: ${{ ! github.event.pull_request }}
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
|
|
|
|||
|
|
@ -22,8 +22,7 @@ RUN apk --no-cache --update add \
|
|||
php81-pdo php81-pdo_mysql php81-pdo_sqlite php81-pdo_pgsql php81-mbstring php81-session php81-bcmath \
|
||||
php81-gd php81-openssl php81-sockets php81-posix php81-ldap php81-simplexml && \
|
||||
rm -rf /var/www/localhost && \
|
||||
rm -f /etc/php81/php-fpm.d/www.conf && \
|
||||
ln -s /usr/bin/php81 /usr/bin/php
|
||||
rm -f /etc/php81/php-fpm.d/www.conf
|
||||
|
||||
ADD . /var/www/app
|
||||
ADD docker/ /
|
||||
|
|
|
|||
Loading…
Reference in New Issue