Skip to content

Commit

Permalink
Merge pull request #83 from laradock/fix-arm64
Browse files Browse the repository at this point in the history
Fix arm64 part image build
  • Loading branch information
bestlong authored Feb 24, 2025
2 parents be9d814 + 380c709 commit e789eb0
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 2 deletions.
18 changes: 18 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false

[*.yml]
indent_size = 2
5 changes: 3 additions & 2 deletions .github/workflows/dockerimage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jobs:
matrix:
# "5.6", "7.0", "7.1", "7.2", "7.3",
php_version: ["7.4", "8.0", "8.1", "8.2", "8.3", "8.4"]
# continue-on-error: true
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -49,7 +50,7 @@ jobs:
uses: docker/build-push-action@v5
with:
file: Dockerfile-${{ matrix.php_version }}
# skip linux/arm64
platforms: linux/amd64,linux/386,linux/arm/v7,linux/arm/v6
# skip linux/arm64, linux/arm/v7,linux/arm/v6
platforms: linux/amd64, linux/386
push: ${{ (github.event_name != 'pull_request') && (github.repository == 'laradock/php-fpm') && (github.ref == 'refs/heads/master') }}
tags: ${{ steps.meta.outputs.tags }}
56 changes: 56 additions & 0 deletions .github/workflows/dockerimage_arm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Docker Image CI for ARM

on:
push:
branches: '**'
tags: '**'
schedule:
- cron: 0 0 * * 6

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# "5.6", "7.0", "7.1", "7.2", "7.3",
php_version: ["7.4", "8.0", "8.1", "8.2", "8.3", "8.4"]
continue-on-error: true
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
images:
laradock/php-fpm
flavor: |
suffix=-${{ matrix.php_version }}
tags: |
type=schedule,pattern={{date 'YYYYMMDD'}}
type=ref,event=branch
type=semver,pattern={{version}}
type=raw,value=latest
- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Login to Docker Hub
if: ${{ (github.repository == 'laradock/php-fpm') && (github.ref == 'refs/heads/master') }}
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USER }}
password: ${{ secrets.DOCKER_HUB_PASSWORD }}

- name: Build and push
uses: docker/build-push-action@v5
with:
file: Dockerfile-${{ matrix.php_version }}
# platforms: linux/amd64, linux/386, linux/arm64, linux/arm/v7, linux/arm/v6
platforms: linux/arm64
push: ${{ (github.event_name != 'pull_request') && (github.repository == 'laradock/php-fpm') && (github.ref == 'refs/heads/master') }}
tags: ${{ steps.meta.outputs.tags }}

0 comments on commit e789eb0

Please sign in to comment.