diff --git a/.goreleaser.yaml b/.goreleaser.yaml index 84353b3..569a224 100644 --- a/.goreleaser.yaml +++ b/.goreleaser.yaml @@ -3,8 +3,9 @@ version: 2 project_name: zero builds: - - id: zero - main: ./main.go + - env: + - CGO_ENABLED=0 + binary: zero goos: - linux - darwin @@ -14,8 +15,6 @@ builds: - arm64 ldflags: - -s -w -X main.version={{.Version}} - env: - - CGO_ENABLED=0 archives: - id: release_archive @@ -25,44 +24,33 @@ archives: - README.md dockers: - - id: zero-amd64 - goos: linux - goarch: amd64 - image_templates: + - image_templates: - "yarlson/zero:{{ .Version }}-amd64" - "yarlson/zero:latest-amd64" + use: buildx dockerfile: Dockerfile - use: docker build_flag_templates: - "--platform=linux/amd64" - - - id: zero-arm64 - goos: linux + + - image_templates: + - "yarlson/zero:{{ .Version }}-arm64v8" + - "yarlson/zero:latest-arm64v8" + use: buildx goarch: arm64 - image_templates: - - "yarlson/zero:{{ .Version }}-arm64" - - "yarlson/zero:latest-arm64" dockerfile: Dockerfile - use: docker build_flag_templates: - - "--platform=linux/arm64" + - "--platform=linux/arm64/v8" docker_manifests: - - id: zero-version - name_template: yarlson/zero:{{ .Version }} + - name_template: "yarlson/zero:{{ .Version }}" image_templates: - - yarlson/zero:{{ .Version }}-amd64 - - yarlson/zero:{{ .Version }}-arm64 - use: docker - skip_push: auto - - - id: zero-latest - name_template: yarlson/zero:latest + - "yarlson/zero:{{ .Version }}-amd64" + - "yarlson/zero:{{ .Version }}-arm64v8" + + - name_template: "yarlson/zero:latest" image_templates: - - yarlson/zero:latest-amd64 - - yarlson/zero:latest-arm64 - use: docker - skip_push: auto + - "yarlson/zero:latest-amd64" + - "yarlson/zero:latest-arm64v8" release: github: