ci(goreleaser): use docker_v2

This commit is contained in:
criyle 2025-10-06 21:29:21 +00:00
parent 0ef1b987fa
commit 03ad17a4c6
2 changed files with 23 additions and 86 deletions

View File

@ -37,6 +37,9 @@ builds:
goamd64: goamd64:
- v2 - v2
- v3 - v3
ignore:
- goos: windows
goarch: arm
tags: tags:
- nomsgpack - nomsgpack
- grpcnotrace - grpcnotrace
@ -67,6 +70,9 @@ builds:
goamd64: goamd64:
- v2 - v2
- v3 - v3
ignore:
- goos: windows
goarch: arm
tags: tags:
- nomsgpack - nomsgpack
- grpcnotrace - grpcnotrace
@ -128,94 +134,24 @@ nfpms:
# nix: # nix:
# - name: go-judge # - name: go-judge
# license: "mit" # license: "mit"
dockers: dockers_v2:
- image_templates: - images:
- "criyle/go-judge:{{ .Tag }}-amd64" - criyle/go-judge
use: buildx
dockerfile: "Dockerfile.goreleaser" dockerfile: "Dockerfile.goreleaser"
goarch: amd64 tags:
goamd64: v2 - "v{{ .Version }}"
- "{{ if .IsNightly }}nightly{{ end }}"
- "{{ if not .IsNightly }}latest{{ end }}"
extra_files: extra_files:
- "mount.yaml" - "mount.yaml"
build_flag_templates: platforms:
- "--platform=linux/amd64" - linux/amd64
- image_templates: - linux/arm64
- "criyle/go-judge:{{ .Tag }}-arm64" - linux/armv7
use: buildx - linux/armv5
goarch: "arm64" - linux/ppc64le
dockerfile: "Dockerfile.goreleaser" - linux/s390x
extra_files: - linux/riscv64
- "mount.yaml"
build_flag_templates:
- "--platform=linux/arm64"
- image_templates:
- "criyle/go-judge:{{ .Tag }}-armv7"
use: buildx
goarch: "arm"
goarm: "7"
dockerfile: "Dockerfile.goreleaser"
extra_files:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/arm/v7"
- image_templates:
- "criyle/go-judge:{{ .Tag }}-armv5"
use: buildx
goarch: "arm"
goarm: "5"
dockerfile: "Dockerfile.goreleaser"
extra_files:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/arm/v5"
- image_templates:
- "criyle/go-judge:{{ .Tag }}-ppc64le"
use: buildx
dockerfile: "Dockerfile.goreleaser"
goarch: ppc64le
extra_files:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/ppc64le"
- image_templates:
- "criyle/go-judge:{{ .Tag }}-s390x"
use: buildx
dockerfile: "Dockerfile.goreleaser"
goarch: s390x
extra_files:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/s390x"
# Debian is now supporting riscv64 on trixie
- image_templates:
- "criyle/go-judge:{{ .Tag }}-riscv64"
use: buildx
dockerfile: "Dockerfile.goreleaser"
goarch: riscv64
extra_files:
- "mount.yaml"
build_flag_templates:
- "--platform=linux/riscv64"
docker_manifests:
- name_template: "criyle/go-judge:{{ .Tag }}"
image_templates:
- "criyle/go-judge:{{ .Tag }}-amd64"
- "criyle/go-judge:{{ .Tag }}-arm64"
- "criyle/go-judge:{{ .Tag }}-armv7"
- "criyle/go-judge:{{ .Tag }}-armv5"
- "criyle/go-judge:{{ .Tag }}-ppc64le"
- "criyle/go-judge:{{ .Tag }}-s390x"
- "criyle/go-judge:{{ .Tag }}-riscv64"
- name_template: "criyle/go-judge:latest"
image_templates:
- "criyle/go-judge:{{ .Tag }}-amd64"
- "criyle/go-judge:{{ .Tag }}-arm64"
- "criyle/go-judge:{{ .Tag }}-armv7"
- "criyle/go-judge:{{ .Tag }}-armv5"
- "criyle/go-judge:{{ .Tag }}-ppc64le"
- "criyle/go-judge:{{ .Tag }}-s390x"
- "criyle/go-judge:{{ .Tag }}-riscv64"
skip_push: auto
checksum: checksum:
name_template: "checksums.txt" name_template: "checksums.txt"
snapshot: snapshot:

View File

@ -1,4 +1,5 @@
FROM debian:latest FROM debian:latest
ARG TARGETPLATFORM
WORKDIR /opt WORKDIR /opt
ENTRYPOINT [ "/opt/go-judge" ] ENTRYPOINT [ "/opt/go-judge" ]
COPY go-judge mount.yaml /opt/ COPY $TARGETPLATFORM/go-judge mount.yaml /opt/