-
Notifications
You must be signed in to change notification settings - Fork 232
/
.goreleaser.yml
119 lines (103 loc) · 3.35 KB
/
.goreleaser.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
version: 2
before:
hooks:
# weirdly goreleaser doesn't all to include outside of the Go build "root" so need to copy
- cp -r grafana_dashboards ./pgwatch2/
- cp -r webpy ./pgwatch2/
builds:
- dir: pgwatch2
binary: pgwatch2-daemon
env:
- CGO_ENABLED=0
goos:
- linux
goarch:
- amd64
archives:
- name_template: >-
{{ .ProjectName }}_
{{ .Version }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
wrap_in_directory: true
# Archive format. Valid options are `tar.gz`, `gz`, `zip` and `binary`.
# If format is `binary`, no archives are created and the binaries are instead
# uploaded directly.
# Default is `tar.gz`.
format: tar.gz
# Additional files/globs you want to add to the archive.
# Defaults are any files matching `LICENCE*`, `LICENSE*`,
# `README*` and `CHANGELOG*` (case-insensitive).
files:
- ./grafana_dashboards/**/*
- ./webpy/**/*
- ./pgwatch2/metrics/**/*
- ./pgwatch2/config/**/*
- ./pgwatch2/sql/**/*
- ./pgwatch2/startup-scripts/**/*
- ./pgwatch2/bootstrap/**/*
- ./README.md
nfpms:
-
file_name_template: >-
{{ .ProjectName }}_
{{ .Version }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
# Your app's vendor.
# Default is empty.
vendor: CYBERTEC PostgreSQL International GmbH
# Your app's homepage.
# Default is empty.
homepage: https://github.com/cybertec-postgresql/pgwatch2
maintainer: Pavlo Golub <open.an.issue@github.com>
# Your app's description.
# Default is empty.
description: pgwatch2 metrics collector with metric definitions and sample YAML config
# Your app's license.
# Default is empty.
license: BSD 3-Clause License
# Formats to be generated.
formats:
- deb
- rpm
# Packages your package depends on.
dependencies:
# Packages your package recommends installing.
# For RPM packages rpmbuild >= 4.13 is required
recommends:
# Packages your package suggests installing.
# For RPM packages rpmbuild >= 4.13 is required
suggests:
# Packages that conflict with your package.
conflicts:
# Override default /usr/local/bin destination for binaries
bindir: /usr/bin
# Files or directories to add to your package (beyond the binary).
# Keys are source paths/globs to get the files from.
# Values are the destination locations of the files in the package.
contents:
- dst: "/etc/pgwatch2"
type: dir
- src: "./pgwatch2/metrics/*"
dst: "/etc/pgwatch2/metrics"
type: config
- src: "./pgwatch2/config/*"
dst: "/etc/pgwatch2/config"
type: config
- src: "./pgwatch2/sql/*"
dst: "/etc/pgwatch2/sql"
- src: "./pgwatch2/bootstrap/*"
dst: "/etc/pgwatch2/bootstrap"
- src: "./pgwatch2/startup-scripts/pgwatch2.service"
dst: "/etc/pgwatch2/startup-scripts/pgwatch2.service"
- src: "./grafana_dashboards/*"
dst: "/etc/pgwatch2/grafana-dashboards"
- src: "./pgwatch2/webpy/*"
dst: "/etc/pgwatch2/webpy"
- src: "./README.md"
dst: "/etc/pgwatch2/README.md"