Skip to content

Commit

Permalink
Add arm v8 version of containers
Browse files Browse the repository at this point in the history
Signed-off-by: Marco Franssen <[email protected]>
  • Loading branch information
marcofranssen committed Jan 17, 2022
1 parent 342a668 commit 77b311a
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 10 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
53 changes: 46 additions & 7 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,19 +40,36 @@ archives:
- goos: windows
format: zip

checksum:
name_template: 'checksums.txt'

dockers:
- goos: linux
goarch: amd64
use: buildx
image_templates:
- "ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64"
build_flag_templates:
- "--pull"
- "--platform=linux/amd64"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.title={{.ProjectName}}"
- "--label=org.opencontainers.image.description={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version=v{{.Version}}"
- "--label=org.opencontainers.image.licenses=MIT"
- "--label=org.opencontainers.image.vendor=Koninklijke Philips N.V."
extra_files:
- "Makefile"
- "go.mod"
- "go.sum"
- "cmd"
- "lib"
- goos: linux
goarch: arm64
use: buildx
image_templates:
- "philipssoftware/{{ .ProjectName }}:v{{ .Version }}"
- "philipssoftware/{{ .ProjectName }}:{{ .FullCommit }}"
- "ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}"
- "ghcr.io/philips-labs/{{ .ProjectName }}:{{ .FullCommit }}"
- "ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64v8"
build_flag_templates:
- "--pull"
- "--platform=linux/arm64/v8"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.title={{.ProjectName}}"
- "--label=org.opencontainers.image.description={{.ProjectName}}"
Expand All @@ -63,6 +84,24 @@ dockers:
- "cmd"
- "lib"

docker_manifests:
- name_template: 'philipssoftware/{{ .ProjectName }}:v{{ .Version }}'
image_templates:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64v8'
- 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:
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-amd64'
- 'ghcr.io/philips-labs/{{ .ProjectName }}:v{{ .Version }}-arm64v8'
- 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 }}-arm64v8'

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 77b311a

Please sign in to comment.