summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorZhuoyun Wei2016-03-15 22:20:30 +0800
committerZhuoyun Wei2016-03-15 22:20:30 +0800
commit7f6766289adb0b084dc69096b9b4f10119a8bf12 (patch)
tree455e147b74ed645636187f5508d1198a9202bf05 /PKGBUILD
downloadaur-7f6766289adb0b084dc69096b9b4f10119a8bf12.tar.gz
[graphite-api] 1.1.2
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD36
1 files changed, 36 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..0d16ea45ad51
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,36 @@
+# Maintainer: Zhuoyun Wei <wzyboy@wzyboy.org>
+# Based-on: aur/graphite-api-git by Justin Dray <justin@dray.be>
+
+pkgname=graphite-api
+pkgver=1.1.2
+pkgrel=1
+pkgdesc="Graphite-web, without the interface. Just the rendering HTTP API."
+url="https://github.com/brutasse/graphite-api"
+license=('Apache')
+depends=('python' 'python-pytz' 'python-six' 'python-flask' 'python-structlog'
+ 'python-yaml' 'python-tzlocal' 'python-cairocffi' 'python-pyparsing'
+ 'gunicorn')
+makedepends=('python-setuptools' 'python-mock')
+optdepends=('python-flask-cache: For caching'
+ 'python-raven: For sentry support'
+ 'python-statsd: For statsd support')
+backup=('etc/graphite-api.yaml')
+arch=('any')
+source=("https://github.com/brutasse/${pkgname}/archive/${pkgver}.tar.gz"
+ "graphite-api.service")
+sha256sums=('fd370342a510f839f1b4d3b690a0e259e61690b75a5ab00f8dcda4a1c7d644be'
+ '08a960632c1db95ee0c46cdb0b5c8a511cf0fe7c0ffac7a0ed0adb877aa2af37')
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+ python setup.py build
+}
+
+package() {
+ cd "$srcdir/$pkgname-$pkgver"
+ python setup.py install --root="${pkgdir}/" --optimize=1
+ mkdir -p "$pkgdir/var/lib/graphite"
+ install -Dm0644 "$srcdir/graphite-api.service" "$pkgdir/usr/lib/systemd/system/graphite-api.service"
+ install -Dm0644 "$srcdir/$pkgname-$pkgver/fpm/conf/etc/graphite-api.yaml" "$pkgdir/etc/graphite-api.yaml"
+ sed -i 's|/srv/|/var/lib/|g' "$pkgdir/etc/graphite-api.yaml"
+}