Skip to content

Commit d5b0768

Browse files
authored
Merge pull request #938 from CodeForAfrica/chore/build-arm-image
Switch to linux/arm64 images
2 parents f43076c + 0188f8d commit d5b0768

32 files changed

+143
-46
lines changed

.github/workflows/build-docker-image.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ jobs:
3030
with:
3131
fetch-depth: 0
3232

33+
# Add support for more platforms with QEMU (optional)
34+
- name: Set up QEMU
35+
uses: docker/setup-qemu-action@v
36+
3337
- name: Set up Docker Buildx
3438
uses: docker/setup-buildx-action@v3
3539

@@ -57,9 +61,10 @@ jobs:
5761
cache-from: type=local,src=/tmp/.buildx-cache
5862
cache-to: type=local,dest=/tmp/.buildx-cache-new
5963
context: .
60-
target: ${{ inputs.target }}
64+
platforms: linux/arm64
6165
push: true
6266
tags: ${{ inputs.tags }}
67+
target: ${{ inputs.target }}
6368

6469
# Temp fix
6570
# https://github.com/docker/build-push-action/issues/252

.github/workflows/charterafrica-deploy-dev.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: charterAFRICA | Deploy | DEV
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67
paths:
78
- "apps/charterafrica/**"
89
- "Dockerfile"
@@ -32,6 +33,10 @@ jobs:
3233
with:
3334
fetch-depth: 0
3435

36+
# Add support for more platforms with QEMU (optional)
37+
- name: Set up QEMU
38+
uses: docker/setup-qemu-action@v3
39+
3540
- name: Set up Docker Buildx
3641
uses: docker/setup-buildx-action@v3
3742

@@ -63,6 +68,7 @@ jobs:
6368
cache-from: type=local,src=/tmp/.buildx-cache
6469
cache-to: type=local,dest=/tmp/.buildx-cache-new
6570
context: .
71+
platforms: linux/arm64
6672
push: true
6773
secrets: |
6874
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

.github/workflows/charterafrica-deploy-prod.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: charterAFRICA | Deploy | PROD
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67

78
# This allows a subsequently queued workflow run to interrupt previous runs
89
concurrency:
@@ -91,6 +92,8 @@ jobs:
9192
cache-from: type=local,src=/tmp/.buildx-cache
9293
cache-to: type=local,dest=/tmp/.buildx-cache-new
9394
context: .
95+
# TODO(xavier): Follow up if we can switch this to arm64
96+
platforms: linux/amd64
9497
push: true
9598
secrets: |
9699
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

.github/workflows/civicsignalblog-deploy-prod.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: CivicSignal Blog | Deploy | PROD
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67

78
# This allows a subsequently queued workflow run to interrupt previous runs
89
concurrency:
@@ -31,6 +32,10 @@ jobs:
3132
with:
3233
fetch-depth: 0
3334

35+
# Add support for more platforms with QEMU (optional)
36+
- name: Set up QEMU
37+
uses: docker/setup-qemu-action@v3
38+
3439
# Set up Node since it's required by version-check
3540
# https://github.com/EndBug/version-check#github-workflow
3641
- name: Setup Node.js
@@ -84,6 +89,7 @@ jobs:
8489
cache-from: type=local,src=/tmp/.buildx-cache
8590
cache-to: type=local,dest=/tmp/.buildx-cache-new
8691
context: .
92+
platforms: linux/arm64
8793
push: true
8894
secrets: |
8995
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

.github/workflows/climatemappedafrica-deploy-dev.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: Climate Mapped Africa | Deploy | DEV
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67
paths:
78
- "apps/climatemappedafrica/**"
89
- "Dockerfile"
@@ -33,6 +34,10 @@ jobs:
3334
with:
3435
fetch-depth: 0
3536

37+
# Add support for more platforms with QEMU (optional)
38+
- name: Set up QEMU
39+
uses: docker/setup-qemu-action@v3
40+
3641
- name: Set up Docker Buildx
3742
uses: docker/setup-buildx-action@v2
3843

@@ -60,6 +65,7 @@ jobs:
6065
cache-from: type=local,src=/tmp/.buildx-cache
6166
cache-to: type=local,dest=/tmp/.buildx-cache-new
6267
context: .
68+
platforms: linux/arm64
6369
target: climatemappedafrica-runner
6470
push: true
6571
tags: "${{ env.IMAGE_NAME }}:${{ github.sha }}"

.github/workflows/codeforafrica-deploy-dev.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: Code for Africa | Deploy | DEV
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67
paths:
78
- "apps/codeforafrica/**"
89
- "Dockerfile"
@@ -34,6 +35,10 @@ jobs:
3435
with:
3536
fetch-depth: 0
3637

38+
# Add support for more platforms with QEMU (optional)
39+
- name: Set up QEMU
40+
uses: docker/setup-qemu-action@v3
41+
3742
- name: Set up Docker Buildx
3843
uses: docker/setup-buildx-action@v3
3944

@@ -66,6 +71,7 @@ jobs:
6671
cache-from: type=local,src=/tmp/.buildx-cache
6772
cache-to: type=local,dest=/tmp/.buildx-cache-new
6873
context: .
74+
platforms: linux/arm64
6975
push: true
7076
secrets: |
7177
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

.github/workflows/codeforafrica-deploy-prod.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: Code for Africa | Deploy | PROD
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
67

78
# This allows a subsequently queued workflow run to interrupt previous runs
89
concurrency:
@@ -32,6 +33,10 @@ jobs:
3233
with:
3334
fetch-depth: 0
3435

36+
# Add support for more platforms with QEMU (optional)
37+
- name: Set up QEMU
38+
uses: docker/setup-qemu-action@v3
39+
3540
# Set up Node since it's required by version-check
3641
# https://github.com/EndBug/version-check#github-workflow
3742
- name: Setup Node.js
@@ -87,6 +92,7 @@ jobs:
8792
cache-from: type=local,src=/tmp/.buildx-cache
8893
cache-to: type=local,dest=/tmp/.buildx-cache-new
8994
context: .
95+
platforms: linux/arm64
9096
push: true
9197
secrets: |
9298
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

.github/workflows/codeforafrica-deploy-review-app.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ jobs:
6666
cache-from: type=local,src=/tmp/.buildx-cache
6767
cache-to: type=local,dest=/tmp/.buildx-cache-new
6868
context: .
69+
platforms: linux/arm64
6970
target: codeforafrica-runner
7071
push: true
7172
tags: "${{ env.IMAGE_NAME }}:${{ github.sha }}"

.github/workflows/pesayetu-deploy-dev.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@ jobs:
3434
with:
3535
fetch-depth: 0
3636

37+
# Add support for more platforms with QEMU (optional)
38+
- name: Set up QEMU
39+
uses: docker/setup-qemu-action@v3
40+
3741
- name: Set up Docker Buildx
3842
uses: docker/setup-buildx-action@v3
3943

@@ -68,6 +72,7 @@ jobs:
6872
cache-from: type=local,src=/tmp/.buildx-cache
6973
cache-to: type=local,dest=/tmp/.buildx-cache-new
7074
context: .
75+
platforms: linux/arm64
7176
push: true
7277
tags: "${{ env.IMAGE_NAME }}:${{ github.sha }}"
7378
target: pesayetu-runner

.github/workflows/roboshield-deploy-dev.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ name: RoboShield | Deploy | DEV
22

33
on:
44
push:
5-
branches: [main]
5+
branches:
6+
- main
7+
68
paths:
79
- "apps/roboshield/**"
810
- "Dockerfile"
@@ -34,6 +36,10 @@ jobs:
3436
with:
3537
fetch-depth: 0
3638

39+
# Add support for more platforms with QEMU (optional)
40+
- name: Set up QEMU
41+
uses: docker/setup-qemu-action@v3
42+
3743
- name: Set up Docker Buildx
3844
uses: docker/setup-buildx-action@v3
3945

@@ -65,6 +71,7 @@ jobs:
6571
cache-from: type=local,src=/tmp/.buildx-cache
6672
cache-to: type=local,dest=/tmp/.buildx-cache-new
6773
context: .
74+
platforms: linux/arm64
6875
push: true
6976
secrets: |
7077
"sentry_auth_token=${{ secrets.SENTRY_AUTH_TOKEN }}"

0 commit comments

Comments
 (0)