summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustin Dray2015-06-02 17:32:54 +1000
committerJustin Dray2015-06-02 17:32:54 +1000
commite11cde0059425ebad724caf5081baf026a60a319 (patch)
treefd83a7f2a72987aca77173648f40b551237886f7
downloadaur-e11cde0059425ebad724caf5081baf026a60a319.tar.gz
Added diamond
-rw-r--r--.SRCINFO22
-rw-r--r--PKGBUILD29
-rw-r--r--diamond.service9
3 files changed, 60 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..a401c774c6d
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,22 @@
+pkgbase = diamond
+ pkgdesc = Diamond is daemon that collects system metrics and publishes them to graphite and others
+ pkgver = 4.0.41
+ pkgrel = 2
+ url = https://github.com/python-diamond/Diamond
+ arch = any
+ license = mit
+ makedepends = unzip
+ depends = python2
+ depends = python2-configobj
+ optdepends = python2-psycopg2: Postgresql collector
+ optdepends = python2-pysensors: LMSensors collector
+ optdepends = libvirt-python: LibvirtKVM collector
+ optdepends = python2-yaml: PuppetAgent collector
+ backup = etc/diamond/diamond.conf
+ source = https://pypi.python.org/packages/source/d/diamond/diamond-4.0.41.tar.gz
+ source = diamond.service
+ md5sums = 063ee62fc30a678260df582335a583c3
+ md5sums = 98d7bd00ba751ab416c325eda82e740f
+
+pkgname = diamond
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..818300900fe
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,29 @@
+# Maintainer: Justin Dray <justin@dray.be>
+# Contributor: Augusto F. Hack <hack.augusto@gmail.com>
+
+pkgname=diamond
+pkgver=4.0
+pkgrel=1
+pkgdesc="Diamond is daemon that collects system metrics and publishes them to graphite and others"
+arch=(any)
+url="https://github.com/python-diamond/Diamond"
+license=('mit')
+depends=('python2' 'python2-configobj')
+makedepends=('unzip')
+optdepends=('python2-psycopg2: Collect data from postgresql database')
+backup=(etc/diamond/diamond.conf)
+source=("https://github.com/python-diamond/Diamond/archive/v${pkgver}.zip"
+ 'diamond.service')
+md5sums=('87f4e5c1340ce085b3994360da0f8c4d'
+ '65b275caf75c19e5040d3dbcd2a7e688')
+
+package() {
+ cd "$srcdir/Diamond-${pkgver}"
+
+ install -D -m644 "$srcdir/diamond.service" "$pkgdir/usr/lib/systemd/system/diamond.service"
+ python2 setup.py install --root="$pkgdir/" --optimize=1
+ rm "$pkgdir/etc/diamond/diamond.conf.example.windows"
+ mv "$pkgdir/etc/diamond/diamond.conf.example" "$pkgdir/etc/diamond/diamond.conf"
+
+ mkdir -p "$pkgdir/var/log/diamond" "$pkgdir/etc/diamond/collectors"
+}
diff --git a/diamond.service b/diamond.service
new file mode 100644
index 00000000000..6313cea9487
--- /dev/null
+++ b/diamond.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Diamond daemon
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/diamond --foreground --log-stdout
+
+[Install]
+WantedBy=multi-user.target