diff options
author | Agostino Sarubbo <ago@gentoo.org> | 2019-05-02 11:02:27 +0200 |
---|---|---|
committer | Agostino Sarubbo <ago@gentoo.org> | 2019-05-02 11:02:27 +0200 |
commit | 8f097c30e4233ce24ea63b3aaa03dee7946ab2b6 (patch) | |
tree | b767da6c8b3e28786beb04114c9413a6d51debb9 /app-metrics | |
parent | net-misc/babeld: removal (diff) | |
download | ago-8f097c30e4233ce24ea63b3aaa03dee7946ab2b6.tar.gz ago-8f097c30e4233ce24ea63b3aaa03dee7946ab2b6.tar.bz2 ago-8f097c30e4233ce24ea63b3aaa03dee7946ab2b6.zip |
app-metrics/uniloader: First commit for queuemetrics/uniloader
Signed-off-by: Agostino Sarubbo <ago@gentoo.org>
Package-Manager: Portage-2.3.62, Repoman-2.3.11
Diffstat (limited to 'app-metrics')
-rw-r--r-- | app-metrics/uniloader/ChangeLog | 5 | ||||
-rw-r--r-- | app-metrics/uniloader/Manifest | 6 | ||||
-rw-r--r-- | app-metrics/uniloader/files/uniloader.confd | 11 | ||||
-rw-r--r-- | app-metrics/uniloader/files/uniloader.initd | 37 | ||||
-rw-r--r-- | app-metrics/uniloader/metadata.xml | 8 | ||||
-rw-r--r-- | app-metrics/uniloader/uniloader-0.6.0.ebuild | 36 |
6 files changed, 103 insertions, 0 deletions
diff --git a/app-metrics/uniloader/ChangeLog b/app-metrics/uniloader/ChangeLog new file mode 100644 index 0000000..6a29116 --- /dev/null +++ b/app-metrics/uniloader/ChangeLog @@ -0,0 +1,5 @@ +*uniloader-0.6.0 (02 May 2019) + + 02 May 2019; Agostino Sarubbo <ago@gentoo.org> +files/uniloader.confd, + +files/uniloader.initd, +metadata.xml, +uniloader-0.6.0.ebuild: + app-metrics/uniloader: First commit for queuemetrics/uniloader diff --git a/app-metrics/uniloader/Manifest b/app-metrics/uniloader/Manifest new file mode 100644 index 0000000..ff6d12d --- /dev/null +++ b/app-metrics/uniloader/Manifest @@ -0,0 +1,6 @@ +AUX uniloader.confd 304 SHA256 9f33153833f91dc7fa2f577b2ee9c09cb99c6b0f04417850da6ce5cfa8fa5580 SHA512 8a9a04e555740eefd0e94509904e74a466fac45efe0297136be30a40b610869a654c608924d6c482ca20c1d391c3173ef27be591eed9b36cbfa258af4784bce7 WHIRLPOOL 0358096b53e7b5de2ceec8039e9554317c88e8e5f9b66a21b2dadf2f493c7993436260f9d4eea90edd9cb9f589237649599d16f0c02926caa53e61de7cd11ab0 +AUX uniloader.initd 783 SHA256 f9d76ba0a0c945d88e67819d1e9a8b6f4131dd6bfb2e2f0fee3ec5be1fa10b32 SHA512 9370ab062ac37234e1767d2a18d62da8a2aa1cfdc0b03fa5e4cd840dcfb2c11d6d1d3a4d35ba12a83de3529329be63aa2b76dc365edec913dad6946c9c974628 WHIRLPOOL e23b82b6b330d4bb32bf214c44b698e4622e7def13bfa0cca891c3cb3b67d922485e17ea3547fc516b16a846fb14cd89066342943b1a4b62b3bb7e23c511898c +DIST uniloader-0.6.0.tar.gz 12290148 SHA256 1fecf244b9fafefd9cb7012a98e0365d95ba424521738b74ace830526d0a6b3c SHA512 9eefede06f73bbe052a42f21db63480a8ac06c6114d9be326acbcc56a25f68c45c8811963d1174eee7066f16502ec0e4ca60e7b9f8fa7985056ac2a98d9f1ac3 WHIRLPOOL 8fdadc5cb2b28f56437beb301a60ad06d4beb6bcca51054d21209c89f745f75a54c009f11a5b264b6f7e539d514d104f8fc82083fc62e5ec693edd02b742be33 +EBUILD uniloader-0.6.0.ebuild 912 SHA256 84d0d81b3f81b56c480c31c983401a4fd84c5f10ef0f8970c19229d93dd8f228 SHA512 156a0ca8682682a1e399d475a74356d76406b7f03e7fd4396d544e8a88658151fa33d2006a99bb9dfa26dede2cd7f3f525e2436518902be76322a3a2245ff280 WHIRLPOOL 6c0c728a289717e326fe37df03273bf9d25aad9559f1246d0f022466412d750d9bd1f4a1040b3e4880fc4f118176c441ce82cbce1b3de56dfdd1ea6eba7deae9 +MISC ChangeLog 236 SHA256 c5f20f6997cbb640c33382d47af7c812cde91ebe78ded852e39f626ce4090fa9 SHA512 22e7295ce311148cecd9cca1499cd8dbca535c63ba529a674ca5df82751eece9815082ff42c260e876df3b3d999f0e38c9012cbb8004cd949122b6292da9fdea WHIRLPOOL 8cfebab86388723ca08ce2dc68bf94ed26ca3095214168dcbfa046fbe065574cccabc5db4843b7a5dd384b83a035bb893d7d1d248d798e6286596b1ef8a4a18e +MISC metadata.xml 246 SHA256 7865004b5e3824d4a508188497473a0a56c96498237986c4f1f692151bf0a01e SHA512 482630597bd2d56c1eaed7099225b4475aec8768e20bad70ea9d6b96791fa38359ba572ab9ad0fc7ea72f1ab736ed1e92fc3c156c3427b008c7220285edce11c WHIRLPOOL d7c29be66bc7bb8ea3a5c4948597ab70efd83982aaa759f621477aefa2a1203186473bc0ac961685249cf48560e011e1d457a934982c562392c289c85edd39a0 diff --git a/app-metrics/uniloader/files/uniloader.confd b/app-metrics/uniloader/files/uniloader.confd new file mode 100644 index 0000000..d26ecae --- /dev/null +++ b/app-metrics/uniloader/files/uniloader.confd @@ -0,0 +1,11 @@ +UNILOADER_LOGFILE="/var/log/uniloader/uniloader.log" +QUEUELOG="/var/log/asterisk/queue_log" +URI="mysql:tcp(127.0.0.1:3306)/queuemetrics?allowOldPasswords=1" +LOGIN="queuemetrics" +TOKEN="P001" +UPASSWD="javadude" + +# QueueMetrics-Live +#URI=https://my.queuemetrics-live.com/CHANGEME +#LOGIN=webqloader +#TOKEN= diff --git a/app-metrics/uniloader/files/uniloader.initd b/app-metrics/uniloader/files/uniloader.initd new file mode 100644 index 0000000..e7f3f67 --- /dev/null +++ b/app-metrics/uniloader/files/uniloader.initd @@ -0,0 +1,37 @@ +#!/sbin/openrc-run +# Copyright 2019 Agostino Sarubbo <ago@gentoo.org> +# Distributed under the terms of the GNU General Public License v2 + +PIDFILE="/run/uniloader.pid" + +start() { + ebegin "Starting uniloader" + start-stop-daemon \ + --start \ + --quiet \ + --background \ + --stdout ${UNILOADER_LOGFILE} \ + --stderr ${UNILOADER_LOGFILE} \ + --env UPASSWD=${UPASSWD} \ + --user queuemetrics:queuemetrics \ + --make-pidfile --pidfile ${PIDFILE} \ + --exec /opt/uniloader/bin/uniloader \ + -- \ + --src ${QUEUELOG} \ + upload \ + --uri ${URI} \ + --login ${LOGIN} \ + --token ${TOKEN} + eend $? +} + +stop() { + ebegin "Stopping uniloader" + start-stop-daemon \ + --stop \ + --quiet \ + --retry=60 \ + --pidfile ${PIDFILE} \ + --signal=9 + eend $? +} diff --git a/app-metrics/uniloader/metadata.xml b/app-metrics/uniloader/metadata.xml new file mode 100644 index 0000000..4eceb31 --- /dev/null +++ b/app-metrics/uniloader/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>ago@gentoo.org</email> + <name>Agostino Sarubbo</name> + </maintainer> +</pkgmetadata> diff --git a/app-metrics/uniloader/uniloader-0.6.0.ebuild b/app-metrics/uniloader/uniloader-0.6.0.ebuild new file mode 100644 index 0000000..9fc24b2 --- /dev/null +++ b/app-metrics/uniloader/uniloader-0.6.0.ebuild @@ -0,0 +1,36 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# DISCLAIMER: +# This ebuild does NOT follow the Gentoo QA Rules, instead it follows the upstream way to install and run the application + +EAPI=7 + +inherit user + +DESCRIPTION="A go-based program that uploads data to a local or remote QueueMetrics" +HOMEPAGE="https://www.queuemetrics-live.com/uniloader.jsp" +LICENSE="all-rights-reserved" +SRC_URI="https://downloads.loway.ch/qm/${P}.tar.gz" +RESTRICT="mirror" +SLOT="0" +KEYWORDS="~amd64" +IUSE="" + +pkg_setup() { + enewgroup queuemetrics + enewuser queuemetrics -1 -1 -1 queuemetrics +} + +src_install() { + dodir /opt/${PN}/bin + exeinto /opt/${PN}/bin + newexe bin/${PN}_amd64 ${PN} + + keepdir /var/log/${PN} + fowners queuemetrics:queuemetrics /var/log/${PN} + fperms 0750 /var/log/${PN} + + newconfd "${FILESDIR}/${PN}.confd" ${PN} + newinitd "${FILESDIR}/${PN}.initd" ${PN} +} |