Skip to content

Commit a1f69fd

Browse files
committed
arm 64 multi architecture
1 parent 805f5b1 commit a1f69fd

File tree

2 files changed

+68
-13
lines changed

2 files changed

+68
-13
lines changed

.github/workflows/ci-arm-build.yml

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
name: CI ARM64 Build and Push
22

33
on:
4-
# push:
5-
# branches:
6-
# - "master"
7-
# tags-ignore:
8-
# - "*"
9-
# pull_request:
10-
# branches-ignore:
11-
# - "*"
4+
push:
5+
branches:
6+
- "master"
7+
tags-ignore:
8+
- "*"
9+
1210
workflow_dispatch:
1311

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: true
15+
1416
jobs:
1517
build-and-push-arm64:
16-
if: github.event_name == 'workflow_dispatch'
1718
timeout-minutes: 60 # intentionally long to allow for slow builds
1819
runs-on: ubuntu-latest
1920
strategy:
@@ -55,7 +56,3 @@ jobs:
5556
export DOCKER_IMAGE_TAG="$TAG_PREFIX-latest-arm64"
5657
export DOCKER_TARGET_PLATFORMS=linux/arm64
5758
make build push=true
58-
- name: fuse images in the registry for latest tag
59-
run: |
60-
export DOCKER_IMAGE_TAG="$TAG_PREFIX-latest"
61-
make docker-image-fuse SUFFIX=arm64
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: CI Multi-Architecture Fusing
2+
3+
on:
4+
workflow_run:
5+
workflows: ["CI ARM64 Build and Push", "CI"]
6+
types:
7+
- completed
8+
branches:
9+
- "master"
10+
11+
12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: true
15+
16+
jobs:
17+
multi-architecture-fusing:
18+
if: ${{ github.event.workflow_run.conclusion == 'success' }}
19+
timeout-minutes: 60 # intentionally long to allow for slow builds
20+
runs-on: ubuntu-latest
21+
strategy:
22+
matrix:
23+
os: [ubuntu-22.04]
24+
python: ["3.11"]
25+
env:
26+
# secrets can be set in settings/secrets on github
27+
DOCKER_REGISTRY: ${{ secrets.DOCKER_REGISTRY }}
28+
steps:
29+
- uses: actions/checkout@v4
30+
- name: setup QEMU
31+
uses: docker/setup-qemu-action@v3
32+
- name: setup docker buildx
33+
id: buildx
34+
uses: docker/setup-buildx-action@v3
35+
with:
36+
driver: docker-container
37+
- name: expose github runtime for buildx
38+
uses: crazy-max/ghaction-github-runtime@v3
39+
- name: show system environs
40+
run: ./ci/helpers/show_system_versions.bash
41+
- name: login to Dockerhub
42+
uses: docker/login-action@v2
43+
with:
44+
username: ${{ secrets.DOCKER_USERNAME }}
45+
password: ${{ secrets.DOCKER_PASSWORD }}
46+
- name: Set deployment variables
47+
run: |
48+
if [ "${GITHUB_REF}" == "refs/heads/master" ]; then
49+
echo "TAG_PREFIX=master-github" >> $GITHUB_ENV
50+
elif [[ "${GITHUB_REF}" == refs/heads/hotfix_v* ]]; then
51+
echo "TAG_PREFIX=hotfix-github" >> $GITHUB_ENV
52+
elif [[ "${GITHUB_REF}" == refs/heads/hotfix_staging_* ]]; then
53+
echo "TAG_PREFIX=hotfix-staging-github" >> $GITHUB_ENV
54+
fi
55+
- name: fuse images in the registry for latest tag
56+
run: |
57+
export DOCKER_IMAGE_TAG="$TAG_PREFIX-latest"
58+
make docker-image-fuse SUFFIX=arm64

0 commit comments

Comments
 (0)