~dricottone/huttese-apk

ref: 87018efde4f68ffb10a6e3d0d793edc75192581c huttese-apk/prometheus/prometheus-node-exporter/APKBUILD -rw-r--r-- 1.1 KiB
87018efd — Drew DeVault sr.ht/py3-colour: bump pkgrel 4 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
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=prometheus-node-exporter
pkgver=0.18.1
pkgrel=0
pkgdesc="prometheus exporter for machine metrics"
url="https://github.com/prometheus/node_exporter"
arch="all"
license="Apache-2.0"
makedepends="go"
source="
	$pkgname-$pkgver.tar.gz::https://github.com/prometheus/node_exporter/archive/v$pkgver.tar.gz
	prometheus-node-exporter.initd
"
subpackages="$pkgname-openrc"
builddir="$srcdir/node_exporter-$pkgver"

build() {
	cd "$builddir"
	go build
}

check() {
	cd "$builddir"
	go test
}

package() {
	cd "$builddir"
    mkdir -p "$pkgdir"/usr/bin
    mkdir -p "$pkgdir"/etc/init.d
	install -Dm755 node_exporter "$pkgdir"/usr/bin/prometheus_node_exporter
	install -Dm755 "$srcdir"/prometheus-node-exporter.initd \
		"$pkgdir"/etc/init.d/prometheus-node-exporter
}

sha512sums="cf2b854fbec1ba39b18432cdc11ab507ebc5b2828e6b34b4f49af9b949fcd365cb3e5eb1e265d0825783810c6b1572a8b3512ec27a46e5c83f89a505590159c0  prometheus-node-exporter-0.18.1.tar.gz
b3034209d6f6f01317a76005de4110407f0ca55c08fd1a6261162485b344289e347d5c3bebece2f571d97fb1c757f897560344c98d7d651675d5ca466d26e3ef  prometheus-node-exporter.initd"