-
Notifications
You must be signed in to change notification settings - Fork 4
68 lines (62 loc) · 1.88 KB
/
docker-multiarch.yml
File metadata and controls
68 lines (62 loc) · 1.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: Docker Multi-arch Build
on:
workflow_call:
inputs:
image-name:
required: true
type: string
jobs:
build-amd64:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
- name: install rops
uses: quantmind/rops/.github/actions/setup-rops@main
- name: build amd64
run: rops docker build ${{ inputs.image-name }}
- name: push amd64
run: rops docker push ${{ inputs.image-name }} --arch
build-arm64:
runs-on: ubuntu-24.04-arm
env:
GITHUB_TOKEN: ${{ github.token }}
DOCKER_BUILDKIT: 0
steps:
- uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
- name: install rops
uses: quantmind/rops/.github/actions/setup-rops@main
- name: build arm64
run: rops docker build ${{ inputs.image-name }}
- name: push arm64
run: rops docker push ${{ inputs.image-name }} --arch
manifest:
needs: [build-amd64, build-arm64]
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
- name: install rops
uses: quantmind/rops/.github/actions/setup-rops@main
- name: create manifest
run: rops docker manifest ${{ inputs.image-name }}