Commit 316c11a9 authored by Michał Polański's avatar Michał Polański

testing/prometheus-node-exporter: upgrade to 1.0.0

parent 27a100cd
Pipeline #20869 passed with stages
in 2 minutes and 50 seconds
......@@ -2,43 +2,44 @@
# Maintainer: Tiago Ilieve <tiago.myhro@gmail.com>
pkgname=prometheus-node-exporter
_pkgname=node_exporter
pkgver=0.18.1
pkgrel=3
pkgver=1.0.0
pkgrel=0
pkgdesc="Prometheus exporter for machine metrics"
url="https://github.com/prometheus/node_exporter"
arch="all"
license="Apache-2.0"
makedepends="go>=1.11 bash sed"
makedepends="go>=1.14 bash sed"
install="$pkgname.pre-install $pkgname.pre-upgrade"
subpackages="$pkgname-openrc"
source="$_pkgname-$pkgver.tar.gz::https://github.com/prometheus/node_exporter/archive/v$pkgver.tar.gz
disable-go-race-detector.patch
node-exporter.initd
node-exporter.confd
node-exporter.initd"
disable-go-race-detector.patch"
builddir="$srcdir/$_pkgname-$pkgver"
build() {
cd "$builddir"
go build -v -ldflags "-s -w -X github.com/prometheus/common/version.Version=$pkgver" -o node_exporter
go build \
-ldflags "-s -w -X github.com/prometheus/common/version.Version=$pkgver" \
-v -o node_exporter
}
check() {
cd "$builddir"
make test
./node_exporter --version
}
package() {
cd "$builddir"
install -Dm755 node_exporter "$pkgdir"/usr/bin/node_exporter
install -Dm755 "$srcdir"/node-exporter.initd "$pkgdir"/etc/init.d/node-exporter
install -Dm644 "$srcdir"/node-exporter.confd "$pkgdir"/etc/conf.d/node-exporter
}
install -Dm644 "$srcdir/node-exporter.confd" "$pkgdir"/etc/conf.d/node-exporter
install -Dm755 "$srcdir/node-exporter.initd" "$pkgdir"/etc/init.d/node-exporter
install -Dm755 ./node_exporter "$pkgdir"/usr/bin/node_exporter
cleanup_srcdir() {
go clean -modcache
default_cleanup_srcdir
}
sha512sums="cf2b854fbec1ba39b18432cdc11ab507ebc5b2828e6b34b4f49af9b949fcd365cb3e5eb1e265d0825783810c6b1572a8b3512ec27a46e5c83f89a505590159c0 node_exporter-0.18.1.tar.gz
36952039e5db39aa06a2ca16fa5d318f22eb967e3e9b1363508b2f3d3d0b14e5df111c77ce951bea2f65dd2be0a0a1582be245acfe4641623381a940204e53d9 disable-go-race-detector.patch
sha512sums="618208cc4cac62ef2699b75ea4fef5165c8537322177271cab42237547e077ea05715e203f561cf080cf3dc5383d77b4b1a3802030bd7fa6d04e599b3d4a06ce node_exporter-1.0.0.tar.gz
df006b184c3b2d5e773044838db7143dc3a64e621f4da6b106f41915a07d5cef32933ab9bb44464f10c132f86997ae7753ae19627afd4ba6cfb125161786dfe0 node-exporter.initd
592d3f17a3cf487d97a14c803dded07d2dfb112b159ab1a3575310fc0176fc3255ddad6657f16a8d6d3c161bfb03c203a6271ec6e6395b75716a14b0de8baced node-exporter.confd
df006b184c3b2d5e773044838db7143dc3a64e621f4da6b106f41915a07d5cef32933ab9bb44464f10c132f86997ae7753ae19627afd4ba6cfb125161786dfe0 node-exporter.initd"
36952039e5db39aa06a2ca16fa5d318f22eb967e3e9b1363508b2f3d3d0b14e5df111c77ce951bea2f65dd2be0a0a1582be245acfe4641623381a940204e53d9 disable-go-race-detector.patch"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment