Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 182828 Details for
Bug 256026
net-p2p/rtorrent using app-misc/dtach as daemonizer
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
init script for version with dtach
rtorrentd.init.dtach (text/plain), 1.23 KB, created by
Stanislav Cymbalov
on 2009-02-22 22:31:37 UTC
(
hide
)
Description:
init script for version with dtach
Filename:
MIME Type:
Creator:
Stanislav Cymbalov
Created:
2009-02-22 22:31:37 UTC
Size:
1.23 KB
patch
obsolete
>#!/sbin/runscript ># Copyright 1999-2008 Gentoo Foundation ># Distributed under the terms of the GNU General Public License v2 ># $Header: $ > >depend() { > need net >} > >checkconfig() { > if [ -z ${USER} ]; then > eerror "USER unset, please edit /etc/conf.d/rtorrent first" > return 1 > fi > > if [ -z ${SOCKET} ]; then > eerror "SOCKET unset, please edit /etc/conf.d/rtorrent first" > return 1 > fi > > if [ -z ${USED_TERM} ]; then > USED_TERM="linux" > fi > > return 0 >} > >start() { > ebegin "Starting rtorrentd" > > checkconfig || return 1 > > pids=$(pidof -x rtorrent) > > HOME=/home/${USER} \ > TERM=${USED_TERM} \ > start-stop-daemon --start \ > --chuid ${USER} \ > --exec /usr/bin/dtach -- -n ${SOCKET} /usr/bin/rtorrent > > if [ $? -eq 0 ]; then > echo $pids $(pidof -x rtorrent) | tr [:blank:] \\n | sort | uniq --unique > /var/run/rtorrentd.pid > chmod g+rw ${SOCKET} > /dev/null > eend 0 > else > eend 1 > fi >} > >stop() { > if [ -z ${TERM_TIMEOUT} -o ${TERM_TIMEOUT} -le 0 ]; then > TERM_TIMEOUT=10 > fi > > ebegin "Stopping rtorrentd" > start-stop-daemon --stop --retry -2/${TERM_TIMEOUT} --pidfile /var/run/rtorrentd.pid > if [ $? -ne 0 ]; then > ewarn "Timeout reached! Sending KILL signal." > start-stop-daemon --stop --signal KILL --pidfile /var/run/rtorrentd.pid > fi > eend $? >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 256026
:
182084
|
182086
|
182087
|
182826
| 182828 |
182830
|
182832
|
182833
|
182835
|
261363
|
365814