void-packages/srcpkgs/telegraf/template

38 lines
1020 B
Bash

# Template file for 'telegraf'
pkgname=telegraf
version=1.3.5
revision=1
_branch=release-1.3
_commit=0f419e9a
build_style="go"
nocross=https://travis-ci.org/kulinacs/void-packages/jobs/258706435
go_import_path="github.com/influxdata/${pkgname}"
build_wrksrc="_build-${pkgname}-xbps/src/${go_import_path}"
hostmakedepends="go-gdm git"
system_accounts="_telegraf"
short_desc="The plugin-driven server agent for collecting & reporting metrics"
maintainer="Nicklaus McClendon <nicklaus@kulinacs.com>"
license="MIT"
homepage="https://www.influxdata.com/time-series-platform/telegraf/"
distfiles="https://github.com/influxdata/${pkgname}/archive/${version}.tar.gz"
checksum=b4663e57b0ca71c9d126a8fdd87b64a0ab2b5bd5fa98ba579f0deb00aac27d4c
post_extract() {
local path="${GOPATH}/src/${go_import_path}"
mkdir -p "$(dirname ${path})"
ln -fs $PWD "${path}"
}
pre_build() {
gdm restore
}
do_build() {
make build VERSION=${version} BRANCH=${_branch} COMMIT=${_commit}
}
post_install() {
vlicense LICENSE
vsv ${pkgname}
}