summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJukka Ruohonen <drear@iki.fi>2007-11-09 13:59:44 +0000
committerJukka Ruohonen <drear@iki.fi>2007-11-09 13:59:44 +0000
commit42ce6de0c3d14388515d85dd766ed8bd3452179f (patch)
tree4b01eff2edf61b660ebb16df4817a5c00fce3abb /net-analyzer/daemonlogger
parentFix typo in sci-libs/openfoam mask entry (diff)
downloadsunrise-42ce6de0c3d14388515d85dd766ed8bd3452179f.tar.gz
sunrise-42ce6de0c3d14388515d85dd766ed8bd3452179f.tar.bz2
sunrise-42ce6de0c3d14388515d85dd766ed8bd3452179f.zip
net-analyzer/daemonlogger: Added init scripts and modified the ebuild accordingly.
svn path=/sunrise/; revision=5034
Diffstat (limited to 'net-analyzer/daemonlogger')
-rw-r--r--net-analyzer/daemonlogger/ChangeLog4
-rw-r--r--net-analyzer/daemonlogger/Manifest5
-rw-r--r--net-analyzer/daemonlogger/daemonlogger-1.0-r1.ebuild43
-rw-r--r--net-analyzer/daemonlogger/files/daemonlogger-confd19
-rw-r--r--net-analyzer/daemonlogger/files/daemonlogger-initd26
5 files changed, 96 insertions, 1 deletions
diff --git a/net-analyzer/daemonlogger/ChangeLog b/net-analyzer/daemonlogger/ChangeLog
index a4d8feb9d..0041b0010 100644
--- a/net-analyzer/daemonlogger/ChangeLog
+++ b/net-analyzer/daemonlogger/ChangeLog
@@ -2,6 +2,10 @@
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
# $Header: $
+ 09 Nov 2007; Jukka Ruohonen <drear@iki.fi> +files/daemonlogger-confd,
+ +files/daemonlogger-initd, +daemonlogger-1.0-r1.ebuild:
+ Added init scripts and modified the ebuild accordingly.
+
09 Nov 2007; Jakub Moc <jakub@gentoo.org> -daemonlogger-0.91.ebuild:
Remove old.
diff --git a/net-analyzer/daemonlogger/Manifest b/net-analyzer/daemonlogger/Manifest
index 09b48586b..9fabb4dc1 100644
--- a/net-analyzer/daemonlogger/Manifest
+++ b/net-analyzer/daemonlogger/Manifest
@@ -1,5 +1,8 @@
AUX daemonlogger-1.0-version.patch 411 RMD160 b3167cf6943bc63efc45590c745d6847c513aa8d SHA1 3ed3aa72f3493dea3471c2d41ce779adf69b62e7 SHA256 81169f3e4c5364f7e9b6e026031b413576541aedd6573600ad896cedd5d6ce8d
+AUX daemonlogger-confd 618 RMD160 7bdfc86fe18114d32cfede194cea5fe368bc6bfa SHA1 be7453f24b046ec00b9e2fa8640dae59faeb9130 SHA256 673b2037fb0b1831a7831b1742f4252d2c435b07b62b8578cae0b45e89c7fb9a
+AUX daemonlogger-initd 646 RMD160 f383df4b8df97825bf5701f0c9abf62aee3870eb SHA1 24e41522a096a82e08cc0a111c3a03a3e0bb521a SHA256 e096c4389c85232eb9afde0adb74873af7b6bdb000ad4615d5753b3093c3e19c
DIST daemonlogger-1.0.tar.gz 110693 RMD160 47c1d345ad3ea4c9fc868afbfcf16cea5499242c SHA1 6bf5340a931a405b85a41be1cc0f75336d43ad20 SHA256 d056096c73c133cedd1e700a1df04a494a7f94b8753d9b99a946663d1bab9964
+EBUILD daemonlogger-1.0-r1.ebuild 985 RMD160 3a3b4f2a82f847dc56857e945051005874666dbc SHA1 6fda33f9c49eaf2218ee38e2dedf64ff100225a2 SHA256 238ca50aa6f322befb6c2993c0922a18a0815d6440be129ea88bf0cba07ca2d4
EBUILD daemonlogger-1.0.ebuild 650 RMD160 6e2338ced2663927656fdec3b02d1e5832bd6f58 SHA1 667f7cf3cf3d9944e067ebc36e048c790726f5ae SHA256 803dc69409797095e58bb4e3640c104ab807df2329e5764ead6bd9750536194b
-MISC ChangeLog 594 RMD160 f0f36d2eefdb87cc5e806c5c8feb8e5c2336e54a SHA1 00255ae6218e5423b25859ba1a330757ed8de9a8 SHA256 a6dfb180fefc66d15f7d4bf6f75635bd82972638686675741b06dd7e84e81e41
+MISC ChangeLog 783 RMD160 6a35ff78422ad6cb60dc4a4b7fc5061ec2781505 SHA1 28a799e558677a33e886f809f0699ccd9f138641 SHA256 0d4fe260271622b0ae920fa01593ca0bf2aef94af3a1e70e32a4a8ce1c92a7cb
MISC metadata.xml 170 RMD160 645927a396fdc21cdeb089fe42c5397332420ea6 SHA1 ac7f48a14fec325926f9ce1be8fbf1f311b4f2e4 SHA256 d797a2ec6f9dc516c9f9c1a758ee87ad3e8c43101b5dc76c2f872d5bd4639b42
diff --git a/net-analyzer/daemonlogger/daemonlogger-1.0-r1.ebuild b/net-analyzer/daemonlogger/daemonlogger-1.0-r1.ebuild
new file mode 100644
index 000000000..0af19d4af
--- /dev/null
+++ b/net-analyzer/daemonlogger/daemonlogger-1.0-r1.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+inherit eutils
+
+DESCRIPTION="Simple packet logger & soft tap"
+HOMEPAGE="http://www.snort.org/users/roesch/Site/Daemonlogger/Daemonlogger.html"
+SRC_URI="http://www.snort.org/dl/${PN}/${P}.tar.gz
+ http://www.snort.org/users/roesch/code/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND="dev-libs/libdnet
+ net-libs/libpcap"
+RDEPEND="${DEPEND}"
+
+pkg_setup() {
+ enewgroup daemonlogger
+ enewuser daemonlogger -1 -1 /sbin/nologin daemonlogger
+}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}/${P}-version.patch"
+}
+
+src_install() {
+ dosbin daemonlogger
+ dodoc AUTHORS ChangeLog NEWS README
+
+ keepdir /var/log/daemonlogger
+
+ newinitd "${FILESDIR}"/daemonlogger-initd daemonlogger
+ newconfd "${FILESDIR}"/daemonlogger-confd daemonlogger
+
+ fowners daemonlogger:daemonlogger /var/log/daemonlogger
+ fperms 0700 /var/log/daemonlogger
+}
diff --git a/net-analyzer/daemonlogger/files/daemonlogger-confd b/net-analyzer/daemonlogger/files/daemonlogger-confd
new file mode 100644
index 000000000..39240d3a0
--- /dev/null
+++ b/net-analyzer/daemonlogger/files/daemonlogger-confd
@@ -0,0 +1,19 @@
+# Config file for /etc/init.d/daemonlogger.
+# Note that you can run daemonlogger as a non-daemon without the init script.
+
+# Set the listening interface.
+IFACE="eth0"
+
+# Set the output interface for tapping.
+# Note that this disables the logging option below.
+#TAP="eth1"
+
+# The directory to which logged pcap-files are stored.
+LOGDIR="/var/log/daemonlogger"
+
+# The user/group to which the program drops privileges.
+# Note that if you change this, please adjust the permissions of LOGDIR accordingly.
+USER="daemonlogger"
+
+# This gathers the above options.
+DAEMONLOGGER_OPTS="-d -i $IFACE -u $USER -g $USER -l $LOGDIR"
diff --git a/net-analyzer/daemonlogger/files/daemonlogger-initd b/net-analyzer/daemonlogger/files/daemonlogger-initd
new file mode 100644
index 000000000..3d8c36af3
--- /dev/null
+++ b/net-analyzer/daemonlogger/files/daemonlogger-initd
@@ -0,0 +1,26 @@
+#!/sbin/runscript
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+if [[ -n "${TAP}" ]] ; then
+ DAEMONLOGGER_OPTS="${DAEMONLOGGER_OPTS} -o ${TAP}"
+fi
+
+depend() {
+ need net
+}
+
+start() {
+ ebegin "Starting daemonlogger on ${IFACE}"
+ start-stop-daemon --start --exec /usr/sbin/daemonlogger \
+ --pidfile /var/run/daemonlogger_$IFACE.pid --background \
+ -- -P /var/run -p daemonlogger_$IFACE.pid ${DAEMONLOGGER_OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping daemonlogger on ${IFACE}"
+ start-stop-daemon --stop --quiet --retry 5 --pidfile /var/run/daemonlogger_$IFACE.pid
+ eend $?
+}