diff --git a/.goreleaser.yml b/.goreleaser.yml index d611a67..d72ad8d 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -16,22 +16,20 @@ builds: archives: - id: default - replacements: - darwin: Darwin - linux: Linux - windows: Windows - 386: i386 - amd64: x86_64 + name_template: >- + {{ .ProjectName }}_{{ .Version }}_ + {{- title .Os }}_ + {{- if eq .Arch "amd64" }}x86_64 + {{- else if eq .Arch "386" }}i386 + {{- else }}{{ .Arch }}{{ end }} - id: latest - replacements: - darwin: Darwin - linux: Linux - windows: Windows - 386: i386 - amd64: x86_64 - - name_template: "{{ .ProjectName }}_latest_{{ .Os }}_{{ .Arch }}" + name_template: >- + {{ .ProjectName }}_latest_ + {{- title .Os }}_ + {{- if eq .Arch "amd64" }}x86_64 + {{- else if eq .Arch "386" }}i386 + {{- else }}{{ .Arch }}{{ end }} checksum: name_template: 'checksums.txt' @@ -50,14 +48,16 @@ release: name: kustomize-sops dockers: + + - use: buildx # Templates of the Docker image names. - - image_templates: - - "viaductoss/{{ .ProjectName }}:latest" - - "viaductoss/{{ .ProjectName }}:{{ .Tag }}" - - "viaductoss/{{ .ProjectName }}:v{{ .Major }}" - - "quay.io/viaductoss/{{ .ProjectName }}:latest" - - "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}" - - "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}" + image_templates: + - "viaductoss/{{ .ProjectName }}:latest-amd64" + - "viaductoss/{{ .ProjectName }}:{{ .Tag }}-amd64" + - "viaductoss/{{ .ProjectName }}:v{{ .Major }}-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:latest-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}-amd64" # Template of the docker build flags. build_flag_templates: @@ -68,9 +68,6 @@ dockers: - "--label=org.opencontainers.image.version={{.Version}}" - "--platform=linux/amd64" - # For multiple architectures - use: buildx - # If your Dockerfile copies files other than the binary itself, # you should list them here as well. # Note that goreleaser will create the same structure inside the temporary @@ -89,10 +86,13 @@ dockers: # include .git for version - .git/ + - use: buildx # Templates of the Docker image names. - - image_templates: + image_templates: + - "viaductoss/{{ .ProjectName }}:latest-arm64" - "viaductoss/{{ .ProjectName }}:{{ .Tag }}-arm64" - "viaductoss/{{ .ProjectName }}:v{{ .Major }}-arm64" + - "quay.io/viaductoss/{{ .ProjectName }}:latest-arm64" - "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}-arm64" - "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}-arm64" @@ -105,9 +105,6 @@ dockers: - "--label=org.opencontainers.image.version={{.Version}}" - "--platform=linux/arm64" - # For multiple architectures - use: buildx - # If your Dockerfile copies files other than the binary itself, # you should list them here as well. # Note that goreleaser will create the same structure inside the temporary @@ -125,3 +122,36 @@ dockers: - ksops.go # include .git for version - .git/ + +docker_manifests: +- name_template: "viaductoss/{{ .ProjectName }}:latest" + image_templates: + - "viaductoss/{{ .ProjectName }}:latest-amd64" + - "viaductoss/{{ .ProjectName }}:latest-arm64" + +- name_template: "viaductoss/{{ .ProjectName }}:{{ .Tag }}" + image_templates: + - "viaductoss/{{ .ProjectName }}:{{ .Tag }}-amd64" + - "viaductoss/{{ .ProjectName }}:{{ .Tag }}-arm64" + + +- name_template: "viaductoss/{{ .ProjectName }}:v{{ .Major }}" + image_templates: + - "viaductoss/{{ .ProjectName }}:v{{ .Major }}-amd64" + - "viaductoss/{{ .ProjectName }}:v{{ .Major }}-arm64" + +- name_template: "quay.io/viaductoss/{{ .ProjectName }}:latest" + image_templates: + - "quay.io/viaductoss/{{ .ProjectName }}:latest-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:latest-arm64" + +- name_template: "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}" + image_templates: + - "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:{{ .Tag }}-arm64" + + +- name_template: "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}" + image_templates: + - "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}-amd64" + - "quay.io/viaductoss/{{ .ProjectName }}:v{{ .Major }}-arm64" diff --git a/README.md b/README.md index 49fbd6e..a439abc 100644 --- a/README.md +++ b/README.md @@ -351,7 +351,7 @@ spec: # 2. Use an init container to download/copy custom binaries into the emptyDir initContainers: - name: install-ksops - image: viaductoss/ksops:v3.1.0 + image: viaductoss/ksops:v3.1.1 command: ["/bin/sh", "-c"] args: - echo "Installing KSOPS..."; @@ -396,7 +396,7 @@ Alternatively, for more control and faster pod start times you can build a custo ```Dockerfile ARG ARGO_CD_VERSION="v1.7.7" # https://github.com/argoproj/argo-cd/blob/master/Dockerfile -ARG KSOPS_VERSION="v3.1.0" +ARG KSOPS_VERSION="v3.1.1" #--------------------------------------------# #--------Build KSOPS and Kustomize-----------# @@ -453,7 +453,7 @@ repoServer: initContainers: - name: install-ksops - image: viaductoss/ksops:v3.1.0 + image: viaductoss/ksops:v3.1.1 command: ["/bin/sh", "-c"] args: - echo "Installing KSOPS...";