From 92bb57e4db927e931e77f0ec6ff9275fe5a9a15e Mon Sep 17 00:00:00 2001 From: geos_one Date: Sat, 6 Nov 2010 07:14:09 +0000 Subject: [PATCH] net-ftp/oftpd: add init script back git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/linamh@2672 6952d904-891a-0410-993b-d76249ca496b --- net-ftp/oftpd/ChangeLog | 3 +++ net-ftp/oftpd/Manifest | 2 +- net-ftp/oftpd/files/init.d.oftpd-r1 | 29 +++++++++++++++++++++++++++++ 3 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 net-ftp/oftpd/files/init.d.oftpd-r1 diff --git a/net-ftp/oftpd/ChangeLog b/net-ftp/oftpd/ChangeLog index 0958640b..8bd9e332 100644 --- a/net-ftp/oftpd/ChangeLog +++ b/net-ftp/oftpd/ChangeLog @@ -2,6 +2,9 @@ # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 # $Header: $ + 06 Nov 2010; Mario Fetka +files/init.d.oftpd-r1: + add init script back + 06 Nov 2010; Mario Fetka -oftpd-0.3.7-r5.ebuild, +oftpd-0.3.7-r6.ebuild, -files/conf.d.oftpd-r1, +files/conf.d.oftpd-r6, -files/init.d.oftpd-r1: diff --git a/net-ftp/oftpd/Manifest b/net-ftp/oftpd/Manifest index db5e16ca..544468a9 100644 --- a/net-ftp/oftpd/Manifest +++ b/net-ftp/oftpd/Manifest @@ -5,5 +5,5 @@ AUX oftpd-0.3.7-ipv6rel2-1.patch 44765 RMD160 563fafe68e9e1be6b96116b7ae0c242041 AUX oftpd-0.3.7-r4.diff 1254 RMD160 64dbf5d120e03beffb3bce72ce16d647f54c906c SHA1 f8182ff728b0d9752429702e7ca04e79051dfca2 SHA256 4497626ffbbff1134b8940da423a2ad1f8fecba0e743d370e73da756ae949438 DIST oftpd-0.3.7.tar.gz 97364 RMD160 9430607bf0c51847a4e4cc97c84be0495c931183 SHA1 d6d3ce43c009bb68736d50739e9a2f60bede99c1 SHA256 b135cd2bc6c54e03e5374845964eab73d5e567160c15bb4226c1c922b1e6d64e EBUILD oftpd-0.3.7-r6.ebuild 1030 RMD160 f7c031eefa6978cb7402c2291b8d4aa0f282ad2e SHA1 183e9049795dd1feb90784d9c9bcb47aabe31d08 SHA256 0eddbfd2e9371052b8ba1a2a1aafb41b7224e4ff0efb33bae8039d0ad82fd72b -MISC ChangeLog 569 RMD160 563e0da64e455f4635ae1dd1b3ddeb3d60a39806 SHA1 27d8338f3ec467612b5943436f718abd20788c3b SHA256 3e3680b977a8a5c555d9563c1d08e96b8ef18f1c4d5f705814270c36d5bc5d42 +MISC ChangeLog 668 RMD160 c32b7d7b407ce6141f32f22e6d3caba40713a7ed SHA1 2de30e96bc412ca29dcf84ba57e090bfb6b08978 SHA256 b17456cb39c45c46de0c71a1add806e7c11b69c3f60bf4a87576ff7368918033 MISC metadata.xml 1238 RMD160 c82938e77f387291d6a1c3bf9b0d802f2878dd12 SHA1 b5738f14922c69e78cfb867acdc65eeea25977bf SHA256 2c13f98be5fa8bdaf21ac86bcd00bbeb8944df5615de0cfce35ae4c00ef4b4d5 diff --git a/net-ftp/oftpd/files/init.d.oftpd-r1 b/net-ftp/oftpd/files/init.d.oftpd-r1 new file mode 100644 index 00000000..a910b92f --- /dev/null +++ b/net-ftp/oftpd/files/init.d.oftpd-r1 @@ -0,0 +1,29 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-ftp/oftpd/files/init.d.oftpd-r1,v 1.3 2009/06/13 19:31:06 grobian Exp $ + +depend() { + need net +} + +checkconfig() { + if [ -z "${FTPUSER}" ] || [ -z "${FTPROOT}" ] || [ -z "${FTPPORT}" ] ; then + eerror "You need to setup FTPUSER, FTPROOT and FTPPORT in /etc/conf.d/oftpd" + return 1 + fi +} + +start() { + checkconfig || return 1 + + ebegin "Starting oftpd" + start-stop-daemon --start --exec /usr/sbin/oftpd -- -p ${FTPPORT} ${FTPUSER} ${FTPROOT} + eend $? +} + +stop() { + ebegin "Stopping oftpd" + start-stop-daemon --stop --quiet --exec /usr/sbin/oftpd + eend $? +}