summaryrefslogtreecommitdiff
path: root/sysutils/tenshi
diff options
context:
space:
mode:
authorbsiegert <bsiegert@pkgsrc.org>2015-01-13 22:20:03 +0000
committerbsiegert <bsiegert@pkgsrc.org>2015-01-13 22:20:03 +0000
commit21cfec819d697b0001a9022e59f5d5a015879c53 (patch)
treeae0857743f3ebc0fb8b605f86dab9a57f787da7f /sysutils/tenshi
parentb6ef1faa03d62f96f2f8ba1c68295f83add4cb3c (diff)
downloadpkgsrc-21cfec819d697b0001a9022e59f5d5a015879c53.tar.gz
Add a package for tenshi-0.15. By Paul B. Henson in PR pkg/49486.
From DESCR: tenshi is a log monitoring program, designed to watch one or more log files for lines matching user defined regular expressions and report on the matches. The regular expressions are assigned to queues which have an alert interval and a list of mail recipients. Queues can be set to send a notification as soon as there is a log line assigned to it, or to send periodic reports.
Diffstat (limited to 'sysutils/tenshi')
-rw-r--r--sysutils/tenshi/DESCR7
-rw-r--r--sysutils/tenshi/Makefile35
-rw-r--r--sysutils/tenshi/PLIST10
-rw-r--r--sysutils/tenshi/distinfo6
-rw-r--r--sysutils/tenshi/files/smf/manifest.xml32
-rw-r--r--sysutils/tenshi/patches/patch-Makefile44
6 files changed, 134 insertions, 0 deletions
diff --git a/sysutils/tenshi/DESCR b/sysutils/tenshi/DESCR
new file mode 100644
index 00000000000..5d0ec26ed32
--- /dev/null
+++ b/sysutils/tenshi/DESCR
@@ -0,0 +1,7 @@
+tenshi is a log monitoring program, designed to watch one or more log files for
+lines matching user defined regular expressions and report on the matches. The
+regular expressions are assigned to queues which have an alert interval and a
+list of mail recipients.
+
+Queues can be set to send a notification as soon as there is a log line
+assigned to it, or to send periodic reports.
diff --git a/sysutils/tenshi/Makefile b/sysutils/tenshi/Makefile
new file mode 100644
index 00000000000..c150835518e
--- /dev/null
+++ b/sysutils/tenshi/Makefile
@@ -0,0 +1,35 @@
+# $NetBSD: Makefile,v 1.1 2015/01/13 22:20:03 bsiegert Exp $
+#
+
+DISTNAME= tenshi-0.15
+CATEGORIES= sysutils
+MASTER_SITES= http://dev.inversepath.com/download/tenshi/
+
+MAINTAINER= henson@acm.org
+HOMEPAGE= http://www.inversepath.com/tenshi.html
+COMMENT= Log monitoring program to watch and report on log files
+LICENSE= isc
+
+USE_TOOLS+= perl:run
+REPLACE_PERL= tenshi
+EGDIR= share/examples/${PKGBASE}
+CONF_FILES= ${PREFIX}/${EGDIR}/tenshi.conf ${PKG_SYSCONFDIR}/tenshi/tenshi.conf
+BUILD_DEFS+= VARBASE
+
+DEPENDS+= p5-IO-BufferedSelect>=1.0:../../sysutils/p5-IO-BufferedSelect
+
+SUBST_CLASSES+= tenshi
+SUBST_STAGE.tenshi= pre-build
+SUBST_FILES.tenshi= tenshi tenshi.conf tenshi.8
+SUBST_SED.tenshi= -e 's,/etc/tenshi/tenshi.conf,${PKG_SYSCONFDIR}/tenshi.conf,g'
+SUBST_SED.tenshi+= -e 's,/var/run/tenshi.pid,${VARBASE}/lib/tenshi/tenshi.pid,g'
+
+PKG_GROUPS= tenshi
+PKG_USERS= tenshi:tenshi
+PKG_HOME.tenshi= ${VARBASE}/lib/tenshi
+OWN_DIRS_PERMS+= ${VARBASE}/lib/tenshi tenshi tenshi 0700
+OWN_DIRS+= ${PKG_SYSCONFDIR}/tenshi
+
+USE_LANGUAGES= # none
+
+.include "../../mk/bsd.pkg.mk"
diff --git a/sysutils/tenshi/PLIST b/sysutils/tenshi/PLIST
new file mode 100644
index 00000000000..7a9c41b1c56
--- /dev/null
+++ b/sysutils/tenshi/PLIST
@@ -0,0 +1,10 @@
+@comment $NetBSD: PLIST,v 1.1 2015/01/13 22:20:03 bsiegert Exp $
+man/man8/tenshi.8
+sbin/tenshi
+share/doc/${PKGNAME}/CREDITS
+share/doc/${PKGNAME}/Changelog
+share/doc/${PKGNAME}/FAQ
+share/doc/${PKGNAME}/INSTALL
+share/doc/${PKGNAME}/LICENSE
+share/doc/${PKGNAME}/README
+share/examples/tenshi/tenshi.conf
diff --git a/sysutils/tenshi/distinfo b/sysutils/tenshi/distinfo
new file mode 100644
index 00000000000..5a796d7d902
--- /dev/null
+++ b/sysutils/tenshi/distinfo
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1 2015/01/13 22:20:03 bsiegert Exp $
+
+SHA1 (tenshi-0.15.tar.gz) = 7728ce5194079d44b9daf9778d363d940565ebd0
+RMD160 (tenshi-0.15.tar.gz) = 4f95ccf0b9b80df12656dd128023e9a3d48fbcef
+Size (tenshi-0.15.tar.gz) = 28405 bytes
+SHA1 (patch-Makefile) = d310900d30adf55019ad2d27951d900ecc638904
diff --git a/sysutils/tenshi/files/smf/manifest.xml b/sysutils/tenshi/files/smf/manifest.xml
new file mode 100644
index 00000000000..0b3a6c4d768
--- /dev/null
+++ b/sysutils/tenshi/files/smf/manifest.xml
@@ -0,0 +1,32 @@
+<?xml version='1.0'?>
+<!DOCTYPE service_bundle SYSTEM '/usr/share/lib/xml/dtd/service_bundle.dtd.1'>
+<service_bundle type='manifest' name='@SMF_NAME@'>
+ <service name='@SMF_PREFIX@/@SMF_NAME@' type='service' version='1'>
+ <create_default_instance enabled="false" />
+ <single_instance />
+ <dependency name='fs-local' grouping='require_all' restart_on='none' type='service'>
+ <service_fmri value='svc:/system/filesystem/local' />
+ </dependency>
+ <dependency name='system-log' grouping='require_all' restart_on='none' type='service'>
+ <service_fmri value='svc:/system/system-log' />
+ </dependency>
+ <dependency name='config-file' grouping='require_all' restart_on='refresh' type='path'>
+ <service_fmri value='file://@PKG_SYSCONFDIR@/tenshi/tenshi.conf' />
+ </dependency>
+ <exec_method name='start' type='method' exec='@PREFIX@/sbin/tenshi -c @PKG_SYSCONFDIR@/tenshi/tenshi.conf -P @VARBASE@/lib/tenshi/tenshi.pid' timeout_seconds='60' />
+ <exec_method name='stop' type='method' exec=':kill' timeout_seconds='60' />
+ <exec_method name='refresh' type='method' exec=':kill -HUP' timeout_seconds='60' />
+ <property_group name='startd' type='framework'>
+ <propval name='ignore_error' type='astring' value='signal' />
+ </property_group>
+ <template>
+ <common_name>
+ <loctext xml:lang='C'>tenshi log analysis and reporting tool</loctext>
+ </common_name>
+ <documentation>
+ <manpage title='tenshi' section='8' />
+ <doc_link name='tenshi' uri='http://www.inversepath.com/tenshi.html' />
+ </documentation>
+ </template>
+ </service>
+</service_bundle>
diff --git a/sysutils/tenshi/patches/patch-Makefile b/sysutils/tenshi/patches/patch-Makefile
new file mode 100644
index 00000000000..4ca55fa598d
--- /dev/null
+++ b/sysutils/tenshi/patches/patch-Makefile
@@ -0,0 +1,44 @@
+$NetBSD: patch-Makefile,v 1.1 2015/01/13 22:20:03 bsiegert Exp $
+
+Fix install locations.
+
+--- Makefile.orig 2015-01-12 22:03:23.993870619 +0000
++++ Makefile
+@@ -3,11 +3,11 @@
+
+ VERSION = 0.15
+
+-bindir = /usr/sbin
+-sysconfdir = /etc
+-docdir = /usr/share/doc/tenshi-${VERSION}
+-mandir = /usr/share/man
+-libdir = /var/lib/tenshi
++bindir = ${PREFIX}/sbin
++sysconfdir = ${PREFIX}/share/examples
++docdir = ${PREFIX}/share/doc
++mandir = ${PREFIX}/${PKGMANDIR}
++
+
+ DOCS = README INSTALL CREDITS LICENSE Changelog FAQ
+ SAMPLES = tenshi.conf tenshi.debian-init tenshi.gentoo-init tenshi.solaris-init tenshi.redhat-init tenshi.suse-init tenshi.redhat-spec tenshi.suse-spec
+@@ -33,12 +33,11 @@ ${TARBALL}:
+ rm -rf ${DIST_DIR}
+
+ install:
+- install -D tenshi ${DESTDIR}${bindir}/tenshi
+- [ -f ${DESTDIR}${sysconfdir}/tenshi/tenshi.conf ] || \
+- install -g root -m 0644 -D tenshi.conf ${DESTDIR}${sysconfdir}/tenshi/tenshi.conf
+- install -d ${DESTDIR}${docdir}
+- install -m 0644 ${DOCS} ${DESTDIR}${docdir}/
+- [ -d ${DESTDIR}${mandir}/man8 ] || \
+- install -d ${DESTDIR}${mandir}/man8
+- install -g root -m 0644 tenshi.8 ${DESTDIR}${mandir}/man8/
+- install -g root -m 755 -d ${DESTDIR}${libdir}
++ install -d ${DESTDIR}${bindir}
++ install tenshi ${DESTDIR}${bindir}
++ install -d ${DESTDIR}${sysconfdir}/tenshi
++ install tenshi.conf ${DESTDIR}${sysconfdir}/tenshi
++ install -d ${DESTDIR}${docdir}/tenshi-${VERSION}
++ install ${DOCS} ${DESTDIR}${docdir}/tenshi-${VERSION}/
++ install -d ${DESTDIR}${mandir}/man8
++ install tenshi.8 ${DESTDIR}${mandir}/man8/