Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add multi-arch build for minio-operator #433

Merged
merged 1 commit into from
Jan 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 63 additions & 15 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,10 @@ builds:
goos:
- linux
goarch:
- arm64
- amd64
- ppc64le
- s390x
env:
- CGO_ENABLED=0
ldflags:
Expand All @@ -32,6 +35,7 @@ builds:
- -trimpath
hooks:
post: ./package.sh {{ .Path }}

-
id: kubectl-minio
dir: kubectl-minio
Expand All @@ -40,9 +44,16 @@ builds:
- linux
- darwin
- windows
- freebsd
goarch:
- amd64
- arm64
- ppc64le
- s390x
ignore:
- goos: darwin
goarch: arm64
- goos: windows
goarch: arm64
env:
- CGO_ENABLED=0
ldflags:
Expand All @@ -54,20 +65,57 @@ builds:

archives:
-
allow_different_binary_count: true
format: binary

dockers:
-
# GOOS of the built binary that should be used.
goos: linux
# GOARCH of the built binary that should be used.
goarch: amd64
dockerfile: Dockerfile
image_templates:
- "minio/k8s-operator:{{ .Tag }}"
- "minio/k8s-operator:latest"
extra_files:
- LICENSE
- README.md
- CREDITS
- minio-operator.minisig
- image_templates:
- "minio/operator:{{ .Tag }}-amd64"
use_buildx: true
dockerfile: Dockerfile
extra_files:
- LICENSE
- CREDITS
build_flag_templates:
- "--platform=linux/amd64"
- image_templates:
- "minio/operator:{{ .Tag }}-ppc64le"
use_buildx: true
dockerfile: Dockerfile
extra_files:
- LICENSE
- CREDITS
build_flag_templates:
- "--platform=linux/ppc64le"
- image_templates:
- "minio/operator:{{ .Tag }}-s390x"
use_buildx: true
dockerfile: Dockerfile
extra_files:
- LICENSE
- CREDITS
build_flag_templates:
- "--platform=linux/s390x"
- image_templates:
- "minio/operator:{{ .Tag }}-arm64"
use_buildx: true
goarch: arm64
dockerfile: Dockerfile
extra_files:
- LICENSE
- CREDITS
build_flag_templates:
- "--platform=linux/arm64"
docker_manifests:
- name_template: minio/operator:{{ .Tag }}
image_templates:
- minio/operator:{{ .Tag }}-amd64
- minio/operator:{{ .Tag }}-arm64
- minio/operator:{{ .Tag }}-ppc64le
- minio/operator:{{ .Tag }}-s390x
- name_template: minio/operator:latest
image_templates:
- minio/operator:{{ .Tag }}-amd64
- minio/operator:{{ .Tag }}-arm64
- minio/operator:{{ .Tag }}-ppc64le
- minio/operator:{{ .Tag }}-s390x
5 changes: 1 addition & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,17 @@ go 1.13
require (
github.com/dgrijalva/jwt-go v3.2.0+incompatible
github.com/docker/cli v0.0.0-20191017083524-a8ff7f821017
github.com/georgysavva/scany v0.2.7 // indirect
github.com/google/go-containerregistry v0.1.2
github.com/gorilla/mux v1.8.0
github.com/jackc/pgx/v4 v4.10.0 // indirect
github.com/minio/minio v0.0.0-20201203193910-919441d9c4d2
github.com/minio/minio-go/v7 v7.0.6
github.com/secure-io/sio-go v0.3.1 // indirect
github.com/stretchr/testify v1.6.1
golang.org/x/time v0.0.0-20200416051211-89c76fbcd5d1
gopkg.in/yaml.v2 v2.3.0
gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776 // indirect
k8s.io/api v0.18.6
k8s.io/apimachinery v0.18.8
k8s.io/client-go v0.18.6
k8s.io/klog/v2 v2.4.0
sigs.k8s.io/controller-tools v0.4.1 // indirect
sigs.k8s.io/kind v0.9.0 // indirect
)
Loading