Compare commits

..

1 Commits

Author SHA1 Message Date
Ramon Quitales
a9f441933b Update goreleaser configs 2025-01-24 22:40:11 -08:00
4 changed files with 628 additions and 634 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -2,46 +2,48 @@
project_name: pulumi-docker-build project_name: pulumi-docker-build
builds: builds:
- id: build-provider - dir: provider
dir: provider env:
env: - CGO_ENABLED=0
- CGO_ENABLED=0 - GO111MODULE=on
- GO111MODULE=on goos:
goos: - darwin
- darwin - linux
- linux goarch:
goarch: - amd64
- amd64 - arm64
- arm64 ignore: []
ignore: &a1 [] main: ./cmd/pulumi-resource-docker-build/
main: ./cmd/pulumi-resource-docker-build/ ldflags:
ldflags: &a2 - -s
- -s - -w
- -w - -X github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}}
- -X - -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}}
github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}} binary: pulumi-resource-docker-build
- -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}} id: build-provider
binary: pulumi-resource-docker-build - dir: provider
- id: build-provider-sign-windows env:
dir: provider - CGO_ENABLED=0
env: - GO111MODULE=on
- CGO_ENABLED=0 goos:
- GO111MODULE=on - windows
goos: goarch:
- windows - amd64
goarch: - arm64
- amd64 ignore: []
- arm64 main: ./cmd/pulumi-resource-docker-build/
ignore: *a1 ldflags:
main: ./cmd/pulumi-resource-docker-build/ - -s
ldflags: *a2 - -w
binary: pulumi-resource-docker-build - -X github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}}
hooks: - -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}}
post: binary: pulumi-resource-docker-build
- make sign-windows-exe-{{ .Arch }} id: build-provider-sign-windows
hooks:
post: make sign-windows-exe-{{ .Arch }}
archives: archives:
- name_template: "{{ .Binary }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}" - name_template: "{{ .Binary }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}"
id: archive id: archive
snapshot: snapshot:
name_template: "{{ .Tag }}-SNAPSHOT" name_template: "{{ .Tag }}-SNAPSHOT"
changelog: changelog:
@@ -49,9 +51,9 @@ changelog:
release: release:
disable: true disable: true
blobs: blobs:
- provider: s3 - provider: s3
region: us-west-2 region: us-west-2
bucket: get.pulumi.com bucket: get.pulumi.com
folder: releases/plugins/ folder: releases/plugins/
ids: ids:
- archive - archive

View File

@@ -2,46 +2,48 @@
project_name: pulumi-docker-build project_name: pulumi-docker-build
builds: builds:
- id: build-provider - dir: provider
dir: provider env:
env: - CGO_ENABLED=0
- CGO_ENABLED=0 - GO111MODULE=on
- GO111MODULE=on goos:
goos: - darwin
- darwin - linux
- linux goarch:
goarch: - amd64
- amd64 - arm64
- arm64 ignore: []
ignore: &a1 [] main: ./cmd/pulumi-resource-docker-build/
main: ./cmd/pulumi-resource-docker-build/ ldflags:
ldflags: &a2 - -s
- -s - -w
- -w - -X github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}}
- -X - -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}}
github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}} binary: pulumi-resource-docker-build
- -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}} id: build-provider
binary: pulumi-resource-docker-build - dir: provider
- id: build-provider-sign-windows env:
dir: provider - CGO_ENABLED=0
env: - GO111MODULE=on
- CGO_ENABLED=0 goos:
- GO111MODULE=on - windows
goos: goarch:
- windows - amd64
goarch: - arm64
- amd64 ignore: []
- arm64 main: ./cmd/pulumi-resource-docker-build/
ignore: *a1 ldflags:
main: ./cmd/pulumi-resource-docker-build/ - -s
ldflags: *a2 - -w
binary: pulumi-resource-docker-build - -X github.com/pulumi/pulumi-docker-build/provider/pkg/version.Version={{.Tag}}
hooks: - -X github.com/pulumi/pulumi-docker-build/provider.Version={{.Tag}}
post: binary: pulumi-resource-docker-build
- make sign-windows-exe-{{ .Arch }} id: build-provider-sign-windows
hooks:
post: make sign-windows-exe-{{ .Arch }}
archives: archives:
- name_template: "{{ .Binary }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}" - name_template: "{{ .Binary }}-{{ .Tag }}-{{ .Os }}-{{ .Arch }}"
id: archive id: archive
snapshot: snapshot:
name_template: "{{ .Tag }}-SNAPSHOT" name_template: "{{ .Tag }}-SNAPSHOT"
changelog: changelog:
@@ -49,9 +51,9 @@ changelog:
release: release:
disable: false disable: false
blobs: blobs:
- provider: s3 - provider: s3
region: us-west-2 region: us-west-2
bucket: get.pulumi.com bucket: get.pulumi.com
folder: releases/plugins/ folder: releases/plugins/
ids: ids:
- archive - archive

View File

@@ -272,7 +272,7 @@ bin/jsign-6.0.jar:
sign-windows-exe-amd64: GORELEASER_ARCH := amd64_v1 sign-windows-exe-amd64: GORELEASER_ARCH := amd64_v1
sign-windows-exe-arm64: GORELEASER_ARCH := arm64 sign-windows-exe-arm64: GORELEASER_ARCH := arm64
sign-windows-exe-%: SHELL:=/bin/bash
sign-windows-exe-%: bin/jsign-6.0.jar sign-windows-exe-%: bin/jsign-6.0.jar
@# Only sign windows binary if fully configured. @# Only sign windows binary if fully configured.
@# Test variables set by joining with | between and looking for || showing at least one variable is empty. @# Test variables set by joining with | between and looking for || showing at least one variable is empty.
@@ -284,7 +284,7 @@ sign-windows-exe-%: bin/jsign-6.0.jar
echo "To rebuild with signing delete the unsigned windows exe file and rebuild with the fixed configuration"; \ echo "To rebuild with signing delete the unsigned windows exe file and rebuild with the fixed configuration"; \
if [[ "${CI}" == "true" ]]; then exit 1; fi; \ if [[ "${CI}" == "true" ]]; then exit 1; fi; \
else \ else \
file=dist/build-provider-sign-windows_windows_${GORELEASER_ARCH}/pulumi-resource-docker-build.exe; \ file=dist/pulumi-docker-build_windows_${GORELEASER_ARCH}/pulumi-resource-docker-build.exe; \
mv $${file} $${file}.unsigned; \ mv $${file} $${file}.unsigned; \
az login --service-principal \ az login --service-principal \
--username "${AZURE_SIGNING_CLIENT_ID}" \ --username "${AZURE_SIGNING_CLIENT_ID}" \