summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wendler <polynomial-c@gentoo.org>2019-04-20 16:17:47 +0200
committerLars Wendler <polynomial-c@gentoo.org>2019-04-20 16:18:03 +0200
commit71358b809e7f83d15ccac961a52414d643efb6fe (patch)
treed7f73b4583a0f259c36fc631d1a04b4204a90bb3 /net-ftp/pure-ftpd
parentdev-util/appdata-tools: Removed old. (diff)
downloadgentoo-71358b809e7f83d15ccac961a52414d643efb6fe.tar.gz
gentoo-71358b809e7f83d15ccac961a52414d643efb6fe.tar.bz2
gentoo-71358b809e7f83d15ccac961a52414d643efb6fe.zip
net-ftp/pure-ftpd: Drop "need net" dependency in openrc init script
Closes: https://bugs.gentoo.org/514860 Package-Manager: Portage-2.3.64, Repoman-2.3.12 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
Diffstat (limited to 'net-ftp/pure-ftpd')
-rw-r--r--net-ftp/pure-ftpd/files/pure-ftpd.rc1115
1 files changed, 8 insertions, 7 deletions
diff --git a/net-ftp/pure-ftpd/files/pure-ftpd.rc11 b/net-ftp/pure-ftpd/files/pure-ftpd.rc11
index cc17b5afa12d..35270ff33507 100644
--- a/net-ftp/pure-ftpd/files/pure-ftpd.rc11
+++ b/net-ftp/pure-ftpd/files/pure-ftpd.rc11
@@ -1,5 +1,5 @@
#!/sbin/openrc-run
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
ftpd_pidfile="/var/run/pure-ftpd.pid"
@@ -9,11 +9,12 @@ daemon="/usr/sbin/pure-ftpd"
script_daemon="/usr/sbin/pure-uploadscript"
depend() {
- need net
+ need localmount
+ use netmount
}
start_pre() {
- if [ -z "$IS_CONFIGURED" ] ; then
+ if [ -z "${IS_CONFIGURED}" ] ; then
eerror "You need to setup /etc/conf.d/pure-ftpd first!"
return 1
fi
@@ -21,7 +22,7 @@ start_pre() {
start() {
UPSCRIPT=""
- if [ -n "$UPLOADSCRIPT" ] ; then
+ if [ -n "${UPLOADSCRIPT}" ] ; then
UPSCRIPT="--uploadscript"
fi
@@ -42,11 +43,11 @@ start() {
--make-pidfile --background --exec /usr/sbin/pure-ftpd ${WAIT} \
-- $(echo ${FTPD_CONFIG} | sed 's@\([[:space:]]\+\|^\)-B\([[:space:]]\+\|$\)@\1@g')
result=$?
- if [ $result -ne 0 ] ; then
+ if [ ${result} -ne 0 ] ; then
eend 1 "Could not launch Pure-FTPd"
else
eend $result
- if [ -n "$UPLOADSCRIPT" ] ; then
+ if [ -n "${UPLOADSCRIPT}" ] ; then
ebegin "Starting Pure-FTPd upload script"
start-stop-daemon --start --quiet --make-pidfile \
--pidfile ${script_pidfile} \
@@ -58,7 +59,7 @@ start() {
}
stop() {
- if [ -n "$UPLOADSCRIPT" ] ; then
+ if [ -n "${UPLOADSCRIPT}" ] ; then
ebegin "Stopping Pure-FTPd upload script"
start-stop-daemon --stop --retry 20 --quiet \
--pidfile ${script_pidfile}