~dricottone/huttese-apk

ref: 82f7e5353d40e92a057295af09b68fdba27eb1cc huttese-apk/sr.ht/sachet/APKBUILD -rw-r--r-- 1.5 KiB
82f7e535 — Drew DeVault py3-ansi2html: upgrade to 1.7.0 2 years ago
                                                                                
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
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=sachet
pkgver=0.3.0
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
	sachet.yml
"
subpackages="$pkgname-openrc"

build() {
	go mod vendor
	go build \
		-trimpath \
		-mod=vendor \
		-ldflags "-extldflags $LDFLAGS" \
		./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/alertmanager/templates
	install -Dm644 "$srcdir"/sachet.yml \
		"$pkgdir"/etc/alertmanager/sachet.yml
	install -Dm644 examples/telegram.tmpl \
		"$pkgdir"/etc/alertmanager/templates/telegram.tmpl
}

sha512sums="
82197fe8ad36bfc5ba4891f4f16a442180d057ada906166d401dd6ce1e7b43cf19ffa34f209a9b34640ae7fcf26c740fa1bddc7f9e79fc6d7b851c7b08ac4b62  sachet-0.3.0.tar.gz
efe429b994b3c139a3804055ea20fe4a8deaf17f58385b800487b4b8d363d1de817bcac751ae5c4cf16b228f896ff17eab19c5d49c7309174d8f0a07386fb772  sachet.confd
7db8607e588897b508f9515131391e4a650fdc9260f865cdb7e97ad978cfa73a779530826f712232ba1944611b5250aa241a8ce27f73cac32f8bcf68fa6b7c67  sachet.initd
579dd96a930ea02d33e5d084421f873d72b125f4314d7bd7170fe6705adce742abaa626297191779e7edb25a50c03e87b25fd4250f4c08cc175e0674724f2b1e  sachet.yml
"