-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add jobmon to CI process: DEB,RPM,MSI,SPK packages
- Goreleaser config duplication reduced using Env variables - All cagent binaries now have one point of information about package version and license information - csender '--version' output updated to be similar with jobmon.
- Loading branch information
1 parent
b9bcd4a
commit d416aed
Showing
8 changed files
with
113 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,16 @@ | ||
.idea | ||
cmd/cagent/cagent | ||
cmd/jobmon/jobmon | ||
cmd/csender/csender | ||
synology-spk/1_create_package/cagent/cagent | ||
synology-spk/1_create_package/cagent/csender | ||
synology-spk/1_create_package/cagent/jobmon | ||
/cagent | ||
/cagent.exe | ||
/jobmon | ||
/jobmon.exe | ||
/csender | ||
/csender.exe | ||
.DS_Store | ||
dist | ||
config.toml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,38 @@ | ||
env: | ||
- CGO_ENABLED=0 | ||
- PROJECT=github.com/cloudradar-monitoring/cagent | ||
- LICENSE_PROPRIETARY=released under a proprietary license. See license.txt | ||
builds: | ||
- id: cagent | ||
main: ./cmd/cagent | ||
binary: cagent | ||
goos: | ||
- windows | ||
- darwin | ||
- linux | ||
- windows | ||
- darwin | ||
- linux | ||
goarch: | ||
- 386 | ||
- amd64 | ||
- arm | ||
- arm64 | ||
- 386 | ||
- amd64 | ||
- arm | ||
- arm64 | ||
goarm: | ||
- 5 | ||
- 6 | ||
- 7 | ||
- 5 | ||
- 6 | ||
- 7 | ||
# List of combinations of GOOS + GOARCH + GOARM to ignore. | ||
ignore: | ||
- goos: darwin | ||
goarch: 386 | ||
- goos: windows | ||
goarch: arm | ||
- goos: darwin | ||
goarch: arm | ||
- goos: windows | ||
goarch: arm64 | ||
- goos: darwin | ||
goarch: arm64 | ||
- goos: darwin | ||
goarch: 386 | ||
- goos: windows | ||
goarch: arm | ||
- goos: darwin | ||
goarch: arm | ||
- goos: windows | ||
goarch: arm64 | ||
- goos: darwin | ||
goarch: arm64 | ||
ldflags: | ||
- -s -w -X github.com/cloudradar-monitoring/cagent.Version={{.Version}} | ||
env: | ||
- CGO_ENABLED=0 | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}}" | ||
- id: csender | ||
main: ./cmd/csender | ||
binary: csender | ||
|
@@ -60,21 +62,47 @@ builds: | |
- goos: darwin | ||
goarch: arm64 | ||
ldflags: | ||
- -s -w -X main.version={{.Version}} | ||
env: | ||
- CGO_ENABLED=0 | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}}" | ||
- id: jobmon | ||
main: ./cmd/jobmon | ||
binary: jobmon | ||
goos: | ||
- windows | ||
- darwin | ||
- linux | ||
goarch: | ||
- 386 | ||
- amd64 | ||
- arm | ||
- arm64 | ||
goarm: | ||
- 5 | ||
- 6 | ||
- 7 | ||
# List of combinations of GOOS + GOARCH + GOARM to ignore. | ||
ignore: | ||
- goos: darwin | ||
goarch: 386 | ||
- goos: windows | ||
goarch: arm | ||
- goos: darwin | ||
goarch: arm | ||
- goos: windows | ||
goarch: arm64 | ||
- goos: darwin | ||
goarch: arm64 | ||
ldflags: | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}}" | ||
- id: cagent_proprietary | ||
main: ./cmd/cagent | ||
binary: cagent | ||
goos: | ||
- windows | ||
- windows | ||
goarch: | ||
- 386 | ||
- amd64 | ||
- 386 | ||
- amd64 | ||
ldflags: | ||
- -s -w -X github.com/cloudradar-monitoring/cagent.Version={{.Version}} -X "github.com/cloudradar-monitoring/cagent.LicenseInfo=released under a proprietary license. See license.txt" | ||
env: | ||
- CGO_ENABLED=0 | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}} -X \"{{.Env.PROJECT}}.LicenseInfo={{.Env.LICENSE_PROPRIETARY}}\"" | ||
- id: csender_proprietary | ||
main: ./cmd/csender | ||
binary: csender | ||
|
@@ -84,26 +112,35 @@ builds: | |
- 386 | ||
- amd64 | ||
ldflags: | ||
- -s -w -X main.version={{.Version}} -X "main.licenseInfo=released under a proprietary license. See license.txt" | ||
env: | ||
- CGO_ENABLED=0 | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}} -X \"{{.Env.PROJECT}}.LicenseInfo={{.Env.LICENSE_PROPRIETARY}}\"" | ||
- id: jobmon_proprietary | ||
main: ./cmd/jobmon | ||
binary: jobmon | ||
goos: | ||
- windows | ||
goarch: | ||
- 386 | ||
- amd64 | ||
ldflags: | ||
- "-s -w -X {{.Env.PROJECT}}.Version={{.Version}} -X \"{{.Env.PROJECT}}.LicenseInfo={{.Env.LICENSE_PROPRIETARY}}\"" | ||
archives: | ||
- id: cagent | ||
builds: | ||
- cagent | ||
- csender | ||
- jobmon | ||
files: | ||
- README.md | ||
- example.config.toml | ||
- README.md | ||
- example.config.toml | ||
replacements: | ||
darwin: Darwin | ||
linux: Linux | ||
windows: Windows | ||
386: i386 | ||
amd64: x86_64 | ||
format_overrides: | ||
- goos: windows | ||
format: zip | ||
- goos: windows | ||
format: zip | ||
checksum: | ||
name_template: 'checksums.txt' | ||
snapshot: | ||
|
@@ -112,8 +149,8 @@ changelog: | |
sort: asc | ||
filters: | ||
exclude: | ||
- '^docs:' | ||
- '^test:' | ||
- '^docs:' | ||
- '^test:' | ||
nfpm: | ||
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}" | ||
maintainer: CloudRadar GmbH <[email protected]> | ||
|
@@ -125,25 +162,26 @@ nfpm: | |
|
||
# Formats to be generated. | ||
formats: | ||
- deb | ||
- rpm | ||
- deb | ||
- rpm | ||
|
||
dependencies: | ||
- sudo | ||
- sudo | ||
|
||
recommends: | ||
- dmidecode | ||
- usbutils | ||
- ca-certificates | ||
- dbus | ||
- dmidecode | ||
- usbutils | ||
- ca-certificates | ||
- dbus | ||
|
||
# Override default /usr/local/bin destination for binaries | ||
bindir: /usr/bin | ||
|
||
# Empty folders that should be created and managed by the packager implementation. | ||
empty_folders: | ||
- /var/log/cagent | ||
- /etc/cagent | ||
- /var/log/cagent | ||
- /var/lib/cagent/jobmon | ||
- /etc/cagent | ||
|
||
files: | ||
"example.config.toml": "/etc/cagent/example.config.toml" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters