Skip to content

Commit

Permalink
Add multi arch docker images
Browse files Browse the repository at this point in the history
Signed-off-by: Marco Franssen <[email protected]>
  • Loading branch information
marcofranssen committed Jan 14, 2022
1 parent 7510a8c commit b8a7229
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 6 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ jobs:

runs-on: ubuntu-20.04

env:
DOCKER_CLI_EXPERIMENTAL: enabled

steps:
- name: Set up Go
uses: actions/[email protected]
Expand All @@ -81,6 +84,9 @@ jobs:
with:
cosign-release: 'v1.4.1'

- name: Set up QEMU
uses: docker/[email protected]

- name: Checkout
uses: actions/[email protected]
with:
Expand Down
25 changes: 22 additions & 3 deletions .goreleaser.draft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ before:

env:
- CGO_ENABLED=0
- DOCKER_CLI_EXPERIMENTAL=enabled

checksum:
name_template: 'checksums.txt'

builds:
- id: binary
Expand Down Expand Up @@ -36,9 +40,6 @@ archives:
- goos: windows
format: zip

checksum:
name_template: 'checksums.txt'

dockers:
- goos: linux
goarch: amd64
Expand All @@ -63,6 +64,24 @@ dockers:
- "cmd"
- "lib"

docker_manifests:
- name_template: 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}'
image_templates:
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}'
image_templates:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'philipssoftware/{{ .ProjectName }}:{{ .FullCommit }}'
image_templates:
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'ghcr.io/philips-labs/{{ .ProjectName }}:{{ .FullCommit }}'
image_templates:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64'

signs:
- id: checksums
cmd: cosign
Expand Down
25 changes: 22 additions & 3 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ before:

env:
- CGO_ENABLED=0
- DOCKER_CLI_EXPERIMENTAL=enabled

checksum:
name_template: 'checksums.txt'

builds:
- id: binary
Expand Down Expand Up @@ -36,9 +40,6 @@ archives:
- goos: windows
format: zip

checksum:
name_template: 'checksums.txt'

dockers:
- goos: linux
goarch: amd64
Expand All @@ -63,6 +64,24 @@ dockers:
- "cmd"
- "lib"

docker_manifests:
- name_template: 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}'
image_templates:
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}'
image_templates:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'philipssoftware/{{ .ProjectName }}:{{ .FullCommit }}'
image_templates:
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}-arm64'
- name_template: 'ghcr.io/philips-labs/{{ .ProjectName }}:{{ .FullCommit }}'
image_templates:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64'

signs:
- id: checksums
cmd: cosign
Expand Down

0 comments on commit b8a7229

Please sign in to comment.