Skip to content

Docker Build & Release #10

Docker Build & Release

Docker Build & Release #10

Workflow file for this run

name: Docker Build & Release
on:
workflow_dispatch:
push:
tags:
- 'v*.*'
jobs:
gettag:
runs-on: ubuntu-latest
steps:
- name: Set UUID
id: generate-uuid
run: echo "uuid=${{ github.sha }}" >> $GITHUB_OUTPUT
outputs:
uuid: ${{ steps.generate-uuid.outputs.uuid }}
build:
needs: [gettag]
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
# https://github.com/docker/setup-qemu-action
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: arm64
- name: 'Login to GitHub Container Registry'
uses: docker/login-action@v3
with:
username: ${{secrets.DOCKER_USERNAME}}
password: ${{secrets.DOCKER_TOKEN}}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver-opts: image=moby/buildkit:latest
- name: Build and push
uses: docker/build-push-action@v5
with:
registry: docker.io
image: effiana/php8.2-fpm
directory: .
file: php/8.2-fpm/Dockerfile
platforms: linux/amd64,linux/arm64
enableBuildKit: true
multiPlatform: true
overrideDriver: true
addLatest: true
pushImage: true
push: true
cache-from: type=gha
cache-to: type=gha,mode=max
tags: |
effiana/php-8.2-fpm:${{needs.gettag.outputs.uuid}}
effiana/php-8.2-fpm:latest
- name: Build and push
uses: docker/build-push-action@v5
with:
registry: docker.io
image: effiana/php8.2-supervisor
directory: .
file: php/8.2-fpm/Dockerfile
platforms: linux/amd64,linux/arm64
enableBuildKit: true
multiPlatform: true
overrideDriver: true
addLatest: true
pushImage: true
push: true
cache-from: type=gha
cache-to: type=gha,mode=max
tags: |
effiana/php-8.2-supervisor:${{needs.gettag.outputs.uuid}}
effiana/php-8.2-supervisor:latest