fix: update DNS token script to work with Docker Compose profiles #178
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-php | |
on: | |
push: | |
branches: | |
- master | |
tags: | |
pull_request: | |
jobs: | |
build-images: | |
name: Build PHP Docker images | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: available platforms | |
run: echo ${{ steps.buildx.outputs.platforms }} | |
- name: build PHP 8.1 image for ghcr.io | |
working-directory: config/php | |
if: ${{ github.ref == 'refs/heads/master' }} | |
env: | |
GITHUB_PACKAGE_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
USERNAME: ${{ github.actor }} | |
run: | | |
echo ${GITHUB_PACKAGE_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin | |
docker buildx build --push \ | |
--platform linux/amd64,linux/arm64 \ | |
-f Dockerfile.8.1 \ | |
-t ghcr.io/paskal/bitrix-php:8.1 . | |
- name: build PHP 8.2 image for ghcr.io | |
working-directory: config/php | |
if: ${{ github.ref == 'refs/heads/master' }} | |
env: | |
GITHUB_PACKAGE_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
USERNAME: ${{ github.actor }} | |
run: | | |
echo ${GITHUB_PACKAGE_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin | |
docker buildx build --push \ | |
--platform linux/amd64,linux/arm64 \ | |
-f Dockerfile.8.2 \ | |
-t ghcr.io/paskal/bitrix-php:8.2 . | |
- name: build PHP 8.3 image for ghcr.io | |
working-directory: config/php | |
if: ${{ github.ref == 'refs/heads/master' }} | |
env: | |
GITHUB_PACKAGE_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
USERNAME: ${{ github.actor }} | |
run: | | |
echo ${GITHUB_PACKAGE_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin | |
docker buildx build --push \ | |
--platform linux/amd64,linux/arm64 \ | |
-f Dockerfile.8.3 \ | |
-t ghcr.io/paskal/bitrix-php:8.3 . |