summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Clayfield2019-12-19 13:52:38 +0800
committerMichael Clayfield2019-12-19 13:52:38 +0800
commitd272fb4829a8c7fa0d182acdfc679b02a602ff4b (patch)
tree1a1adbeeee32378dd1bd9f16c6e229398fe652d0
downloadaur-d272fb4829a8c7fa0d182acdfc679b02a602ff4b.tar.gz
initial commit
-rw-r--r--.SRCINFO35
-rw-r--r--PKGBUILD29
-rw-r--r--alerta.sysusers1
-rw-r--r--alertad.service11
4 files changed, 76 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..2491d0135031
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,35 @@
+pkgbase = alerta
+ pkgdesc = A tool used to consolidate and de-duplicate alerts from multiple sources
+ pkgver = 7.4.1
+ pkgrel = 1
+ url = https://github.com/alerta/alerta
+ arch = any
+ license = APACHE
+ makedepends = python-setuptools
+ depends = python
+ depends = python-bcrypt
+ depends = python-cryptography
+ depends = python-flask
+ depends = python-flask-cors
+ depends = python-flask-compress
+ depends = python-pyjwt
+ depends = python-pyparsing
+ depends = python-dateutil
+ depends = python-pytz
+ depends = python-pyaml
+ depends = python-requests
+ depends = python-sentry_sdk
+ depends = python-blinker
+ depends = python-pymongo
+ optdepends = python-psycopg2
+ optdepends = postgresql
+ optdepends = mongodb
+ source = https://github.com/alerta/alerta/archive/v7.4.1.tar.gz
+ source = alertad.service
+ source = alerta.sysusers
+ sha256sums = ec85df1e61121a03d8fb84526c0665823ebe4b378e8e3d18f16ecca929d48ba5
+ sha256sums = 4449acb346807229e4cbfeed68d9ba6006a165e65dec09487fb6e627088016c2
+ sha256sums = f0a2f76266ba07275ab2baeab1497dfb2946305e85ae68e3b34dd14e2ac47423
+
+pkgname = alerta
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..447b48af43e9
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,29 @@
+# Maintainer: Michael Clayfield <me@michaelclayfield.com>
+pkgname=alerta
+pkgver=7.4.1
+pkgrel=1
+pkgdesc="A tool used to consolidate and de-duplicate alerts from multiple sources"
+arch=('any')
+url="https://github.com/alerta/alerta"
+license=('APACHE')
+makedepends=('python-setuptools')
+depends=('python' 'python-bcrypt' 'python-cryptography' 'python-flask' 'python-flask-cors' 'python-flask-compress' 'python-pyjwt' 'python-pyparsing' 'python-dateutil' 'python-pytz' 'python-pyaml' 'python-requests' 'python-sentry_sdk' 'python-blinker' 'python-pymongo')
+optdepends=('python-psycopg2' 'postgresql' 'mongodb')
+source=("https://github.com/alerta/alerta/archive/v$pkgver.tar.gz"
+ "${pkgname}d.service"
+ "${pkgname}.sysusers")
+sha256sums=('ec85df1e61121a03d8fb84526c0665823ebe4b378e8e3d18f16ecca929d48ba5'
+ '4449acb346807229e4cbfeed68d9ba6006a165e65dec09487fb6e627088016c2'
+ 'f0a2f76266ba07275ab2baeab1497dfb2946305e85ae68e3b34dd14e2ac47423')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ python setup.py build
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ python setup.py install --root="${pkgdir}"
+ install -Dm644 "${srcdir}/${pkgname}.sysusers" "${pkgdir}/usr/lib/sysusers.d/${pkgname}.conf"
+ install -D -m644 "${srcdir}/${pkgname}d.service" "${pkgdir}/usr/lib/systemd/system/${pkgname}d.service"
+}
diff --git a/alerta.sysusers b/alerta.sysusers
new file mode 100644
index 000000000000..5a2f72e24bd8
--- /dev/null
+++ b/alerta.sysusers
@@ -0,0 +1 @@
+u alerta - "Alerta service account"
diff --git a/alertad.service b/alertad.service
new file mode 100644
index 000000000000..f9eeea479005
--- /dev/null
+++ b/alertad.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Alerta server service
+After=network.target
+
+[Service]
+User=alerta
+ExecStart=/usr/bin/alertad run
+ExecReload=/bin/kill -HUP $MAINPID
+
+[Install]
+WantedBy=multi-user.target