packer-plugin-xenserver/.goreleaser.yml

75 lines
2.3 KiB
YAML
Raw Normal View History

2022-06-08 01:44:22 -05:00
# This is an example goreleaser.yaml file with some sane defaults.
# Make sure to check the documentation at http://goreleaser.com
env:
- CGO_ENABLED=0
before:
hooks:
# TODO(ddelnano): for now there aren't tests to run
2022-06-08 01:44:22 -05:00
# - go test ./...
# As part of the release doc files are included as a separate deliverable for
# consumption by Packer.io. To include a separate docs.zip uncomment the following command.
#- make ci-release-docs
# Check plugin compatibility with required version of the Packer SDK
- make plugin-check
2022-06-08 01:44:22 -05:00
builds:
# A separated build to run the packer-plugins-check only once for a linux_amd64 binary
-
id: plugin-check
mod_timestamp: '{{ .CommitTimestamp }}'
flags:
- -trimpath #removes all file system paths from the compiled executable
ldflags:
- '-s -w -X {{ .ModulePath }}/version.Version={{.Version}} -X {{ .ModulePath }}/version.VersionPrerelease= '
2022-06-08 01:44:22 -05:00
goos:
- linux
goarch:
- amd64
binary: '{{ .ProjectName }}_v{{ .Version }}_{{ .Env.API_VERSION }}_{{ .Os }}_{{ .Arch }}'
-
2022-06-08 01:44:22 -05:00
mod_timestamp: '{{ .CommitTimestamp }}'
flags:
- -trimpath #removes all file system paths from the compiled executable
ldflags:
- '-s -w -X {{ .ModulePath }}/version.Version={{.Version}} -X {{ .ModulePath }}/version.VersionPrerelease= '
2022-06-08 01:44:22 -05:00
goos:
- freebsd
- windows
- linux
- darwin
goarch:
- amd64
- '386'
- arm
- arm64
ignore:
- goos: darwin
goarch: '386'
- goos: linux
goarch: amd64
binary: '{{ .ProjectName }}_v{{ .Version }}_{{ .Env.API_VERSION }}_{{ .Os }}_{{ .Arch }}'
archives:
- format: zip
files:
- none*
2022-06-08 01:44:22 -05:00
name_template: '{{ .ProjectName }}_v{{ .Version }}_{{ .Env.API_VERSION }}_{{ .Os }}_{{ .Arch }}'
checksum:
name_template: '{{ .ProjectName }}_v{{ .Version }}_SHA256SUMS'
algorithm: sha256
signs:
- artifacts: checksum
args:
# if you are using this is in a GitHub action or some other automated pipeline, you
2022-06-08 01:44:22 -05:00
# need to pass the batch flag to indicate its not interactive.
- "--batch"
- "--local-user"
- "{{ .Env.GPG_FINGERPRINT }}"
- "--output"
- "${signature}"
- "--detach-sign"
- "${artifact}"
release:
draft: true
2022-06-08 01:44:22 -05:00
changelog:
skip: true