From ba87314a8c78e6f4d8770b6b1a6125668fdf4656 Mon Sep 17 00:00:00 2001 From: Allan Roger Reid Date: Tue, 27 Aug 2024 16:30:07 -0700 Subject: [PATCH] Update goreleaser to support more architectures (#334) --- .goreleaser.yml | 91 +++++++++++++++++++++++++++++++++++++++++++++++-- Dockerfile | 2 +- 2 files changed, 90 insertions(+), 3 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 25c778e0..ae5d95c6 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -78,6 +78,93 @@ dockers: # GOARCH of the built binary that should be used. goarch: amd64 dockerfile: Dockerfile.release + - image_templates: + - "quay.io/minio/warp:{{ .Tag }}-amd64" + use: buildx + goarch: amd64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/amd64" + - image_templates: + - "quay.io/minio/warp:{{ .Tag }}-arm64" + use: buildx + goarch: arm64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/arm64" + - image_templates: + - "quay.io/minio/warp:latest-amd64" + use: buildx + goarch: amd64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/amd64" + - image_templates: + - "quay.io/minio/warp:latest-arm64" + use: buildx + goarch: arm64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/arm64" + + - image_templates: + - "minio/warp:{{ .Tag }}-amd64" + use: buildx + goarch: amd64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/amd64" + - image_templates: + - "minio/warp:{{ .Tag }}-arm64" + use: buildx + goarch: arm64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/arm64" + - image_templates: + - "minio/warp:latest-amd64" + use: buildx + goarch: amd64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/amd64" + - image_templates: + - "minio/warp:latest-arm64" + use: buildx + goarch: arm64 + ids: + - warp + dockerfile: Dockerfile.release + build_flag_templates: + - "--platform=linux/arm64" +docker_manifests: + - name_template: minio/warp:{{ .Tag }} + image_templates: + - minio/warp:{{ .Tag }}-amd64 + - minio/warp:{{ .Tag }}-arm64 + - name_template: minio/warp:latest + image_templates: + - minio/warp:latest-amd64 + - minio/warp:latest-arm64 + - name_template: quay.io/minio/warp:{{ .Tag }} + image_templates: + - quay.io/minio/warp:{{ .Tag }}-amd64 + - quay.io/minio/warp:{{ .Tag }}-arm64 + - name_template: quay.io/minio/warp:latest image_templates: - - "minio/warp:{{ .Tag }}" - - "minio/warp:latest" + - quay.io/minio/warp:latest-amd64 + - quay.io/minio/warp:latest-arm64 \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index b0f1badb..e30ecbda 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.18 +FROM golang:1.22 ADD go.mod /go/src/github.com/minio/warp/go.mod ADD go.sum /go/src/github.com/minio/warp/go.sum