~dricottone/huttese-apk

ref: 7c54a212f5f87e19b1f5f80d84722aecfcc04d3e huttese-apk/sr.ht/alertmanager/APKBUILD -rw-r--r-- 1.9 KiB
7c54a212 — Drew DeVault alertmanager: add Message-ID patch 4 years ago
                                                                                
06c053e6 Drew DeVault
b0a1695f Drew DeVault
7c54a212 Drew DeVault
06c053e6 Drew DeVault
3312d494 Drew DeVault
06c053e6 Drew DeVault
3312d494 Drew DeVault
06c053e6 Drew DeVault
7c54a212 Drew DeVault
06c053e6 Drew DeVault
3312d494 Drew DeVault
06c053e6 Drew DeVault
7c54a212 Drew DeVault
06c053e6 Drew DeVault
3312d494 Drew DeVault
3b9a1d9b Drew DeVault
3312d494 Drew DeVault
3b9a1d9b Drew DeVault
3312d494 Drew DeVault
3b9a1d9b Drew DeVault
3312d494 Drew DeVault
3b9a1d9b Drew DeVault
3312d494 Drew DeVault
06c053e6 Drew DeVault
3312d494 Drew DeVault
06c053e6 Drew DeVault
b0a1695f Drew DeVault
3bdbd410 Drew DeVault
7c54a212 Drew DeVault
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
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=alertmanager
pkgver=0.19.0
pkgrel=6
pkgdesc="Prometheus Alertmanager"
url="https://github.com/prometheus/alertmanager"
arch="all"
license="Apache-2.0"
install="$pkgname.pre-install"
makedepends="go bzr"
source="
	$pkgname-$pkgver.tar.gz::https://github.com/prometheus/alertmanager/archive/v$pkgver.tar.gz
	alertmanager.confd
	alertmanager.initd
	0001-email-generate-message-ID-headers.patch
"
subpackages="$pkgname-openrc"
builddir="$srcdir/$pkgname-$pkgver"
options="!check" # timing-dependent upstream failures

prepare() {
	default_prepare
	go mod vendor
}

build() {
	go build \
		-trimpath \
		-mod=vendor \
		-ldflags "-extldflags $LDFLAGS" \
		-tags netgo \
		./cmd/alertmanager
	go build \
		-trimpath \
		-mod=vendor \
		-ldflags "-extldflags $LDFLAGS" \
		-tags netgo \
		./cmd/amtool
}

check() {
	go test ./...
}

package() {
	install -Dm755 alertmanager "$pkgdir"/usr/bin/alertmanager
	install -Dm755 amtool "$pkgdir"/usr/bin/amtool

	install -Dm755 "$srcdir"/alertmanager.initd \
		"$pkgdir"/etc/init.d/alertmanager
	install -Dm644 "$srcdir"/alertmanager.confd \
		"$pkgdir"/etc/conf.d/alertmanager
	install -dm644 "$pkgdir"/var/lib/alertmanager/data

	install -Dm644 examples/ha/alertmanager.yml \
		"$pkgdir"/etc/alertmanager/alertmanager.yml
}

sha512sums="2c21bfbb1001e07e81b1115439ad15e7c0e7089839e56a19c445177e322b8ef9aa2b85e96478f3c3d709cbbd3a5447662a8c55da370b84aa4b6b24f83848744b  alertmanager-0.19.0.tar.gz
58420cf10ed51ec389d21ffdd5b4a0e588f0dc78b1069e32d0db1e0215f64c1c980d8f539ae902839f2f9342090b50ce1db756839f3676ee18b77548ce8f99c8  alertmanager.confd
def36c9933e91a38d863c06679efd840952ba003a839afe5b5c6423fa6ee8f229755f758c5363564b433756af34509fef282b81dea2532500f1287c47c426787  alertmanager.initd
7df6fb27a22b12f006f2f0ba0b6b807c07611a1c63fecee67de04d0899f4ba9924b62281f43289e4519ae6313a0b1bf47bce7a3401c91ef6f49e943638e84ae1  0001-email-generate-message-ID-headers.patch"