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
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=sachet
pkgver=0.2.2
pkgrel=0
pkgdesc="Prometheus Alertmanager"
url="https://github.com/messagebird/sachet"
arch="all"
license="Apache-2.0"
install="$pkgname.pre-install"
makedepends="go"
source="
$pkgname-$pkgver.tar.gz::https://github.com/messagebird/sachet/archive/$pkgver.tar.gz
sachet.confd
sachet.initd
config.yml
"
subpackages="$pkgname-openrc"
build() {
go build \
-trimpath \
-mod=vendor \
-ldflags "-extldflags $LDFLAGS" \
-tags netgo \
./cmd/sachet
}
check() {
go test ./...
}
package() {
install -Dm755 sachet "$pkgdir"/usr/bin/sachet
install -Dm755 "$srcdir"/sachet.initd \
"$pkgdir"/etc/init.d/sachet
install -Dm644 "$srcdir"/sachet.confd \
"$pkgdir"/etc/conf.d/sachet
mkdir -p "$pkgdir"/etc/sachet
install -Dm644 "$srcdir"/config.yml \
"$pkgdir"/etc/sachet/config.yml
install -Dm644 examples/telegram.tmpl \
"$pkgdir"/etc/sachet/telegram.tmpl
}
sha512sums="3684090505403cff65cd05e2c6b61cf930dd0d7e461c355963417197bdd6306b837dbc5933b34676646cc9ae480190313c1aebfa81699581d0aafff377127e92 sachet-0.2.2.tar.gz
9516a5a26ecfff4b6511084df346ee66fd923522d2750ce5deb894980c7782f5175ebd83a5a401a384f6caa28c1aa436de56660538f417fa6c71d9e4397b6bf4 sachet.confd
68fc6733011d854d5dabbc6e646774b5c9cc78fce2a79b14ab8d4eb760fad86aac62149847ed9749198e9a46cc65e8bc5a4894c8dafe3c750e4a9fe7c81b066d sachet.initd
579dd96a930ea02d33e5d084421f873d72b125f4314d7bd7170fe6705adce742abaa626297191779e7edb25a50c03e87b25fd4250f4c08cc175e0674724f2b1e config.yml"