Les voici :
.rtorrent.rc
schedule = chmod,0,0,"execute=chmod,777,/home/alexis/.session/ale.socket"
execute = {sh,-c,rm -f /home/alexis/.session/ale.socket}
scgi_local = /home/alexis/.session/ale.socket
execute = {sh,-c,chmod 0666 /home/alexis/.session/ale.socket}
encoding_list = UTF-8
port_range = 45000-65000
port_random = no
check_hash = no
directory = /home/alexis/torrents
session = /home/alexis/.session
encryption = allow_incoming, try_outgoing, enable_retry
schedule = watch_directory,1,1,"load_start=/home/alexis/watch/*.torrent"
schedule = untied_directory,5,5,"stop_untied=/home/alexis/watch/*.torrent"
use_udp_trackers = yes
dht = off
peer_exchange = no
execute = {sh,-c,/usr/bin/php /var/www/rutorrent/php/initplugins.php alexis &}
lighttpd.conf
erver.modules = (
"mod_access",
"mod_alias",
"mod_compress",
"mod_redirect",
# "mod_rewrite",
)
server.document-root = "/var/www"
server.upload-dirs = ( "/var/cache/lighttpd/uploads" )
server.errorlog = "/var/log/lighttpd/error.log"
server.pid-file = "/var/run/lighttpd.pid"
server.username = "www-data"
server.groupname = "www-data"
server.port = 80
index-file.names = ( "index.php", "index.html", "index.lighttpd.html"$
url.access-deny = ( "~", ".inc" )
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
compress.cache-dir = "/var/cache/lighttpd/compress/"
compress.filetype = ( "application/javascript", "text/css", "text/html$
# default listening port for IPv6 falls back to the IPv4 port
include_shell "/usr/share/lighttpd/use-ipv6.pl " + server.port
include_shell "/usr/share/lighttpd/create-mime.assign.pl"
include_shell "/usr/share/lighttpd/include-conf-enabled.pl"
fastcgi.server = ( ".php" => ((
"bin-path" => "/usr/bin/php5-cgi",
"socket" => "/tmp/php.socket"
)))
$SERVER["socket"] == ":443" {
ssl.engine = "enable"
ssl.pemfile = "/etc/lighttpd/certs/lighttpd.pem"
}
server.modules += ( "mod_auth" )
auth.backend = "htdigest"
auth.backend.htdigest.userfile = "/etc/lighttpd/.auth"
auth.require = ( "/rutorrent/" =>
(
"method" => "digest",
"realm" => "ruTorrent Seedbox",
"require" => "valid-user"
),
"/ALE0" => (
"method" => "digest",
"realm" => "ruTorrent Seedbox",
"require" => "user=alexis",
),
)
server.modules += ( "mod_scgi" )
scgi.server = (
"/ALE0" =>
( "127.0.0.1" =>
(
"socket" => "/home/alexis/.session/ale.socket",
"check-local" => "disable",
"disable-time" => 0, # don't disable scgi if connection fails
)
),
)
config.php
<?php
$topDirectory = '/home/alexis';
$scgi_port = 0;
$scgi_host = "unix:///home/alexis/.session/ale.socket";
$XMLRPCMountPoint = "/ALE0";
?></pre>
.rtord
#!/bin/bash
### BEGIN INIT INFO
# Provides: rtorrent.alexis
# Required-Start:
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start daemon at boot time
# Description: Start-Stop rtorrent user session
### END INIT INFO
user="alexis"
# the full path to the filename where you store your rtorrent configuration
config="/home/alexis/.rtorrent.rc"
# set of options to run with
options=""
# default directory for screen, needs to be an absolute path
base="/home/alexis"
# name of screen session
srnname="rtorrent"
# file to log to (makes for easier debugging if something goes wrong)
logfile="/var/log/rtorrentInit.log"
#######################
###END CONFIGURATION###
#######################
PATH=/usr/bin:/usr/local/bin:/usr/local/sbin:/sbin:/bin:/usr/sbin
DESC="rtorrent"
NAME=rtorrent
DAEMON=$NAME
SCRIPTNAME=/etc/init.d/$NAME
checkcnfg() {
exists=0
for i in `echo "$PATH" | tr ':' '\n'` ; do
if [ -f $i/$NAME ] ; then
exists=1
break
fi
done
if [ $exists -eq 0 ] ; then
echo "cannot find rtorrent binary in PATH $PATH" | tee -a "$logfile" >&2
exit 3
fi
if ! [ -r "${config}" ] ; then
echo "cannot find readable config ${config}. check that it is there and permissio$
exit 3
fi
session=`getsession "$config"`
if ! [ -d "${session}" ] ; then
echo "cannot find readable session directory ${session} from config ${config}. ch$
exit 3
fi
}
d_start() {
[ -d "${base}" ] && cd "${base}"
stty stop undef && stty start undef
su -c "screen -ls | grep -sq "\.${srnname}[[:space:]]" " ${user} || su -c "screen -dm -$
su -c "screen -S "${srnname}" -X screen rtorrent ${options} 2>&1 1>/dev/null" ${user} |$
}
d_stop() {
session=`getsession "$config"`
if ! [ -s ${session}/rtorrent.lock ] ; then
return
fi
pid=`cat ${session}/rtorrent.lock | awk -F: '{print($2)}' | sed "s/[^0-9]//g"`
if ps -A | grep -sq ${pid}.*rtorrent ; then # make sure the pid doesn't belong to ano$
kill -s INT ${pid}
fi
}
getsession() {
session=`cat "$1" | grep "^[[:space:]]*session[[:space:]]*=" | sed "s/^[[:space:]]*se$
echo $session
}
checkcnfg
case "$1" in
start)
echo -n "Starting $DESC: $NAME"
d_start
echo "."
;;
stop)
echo -n "Stopping $DESC: $NAME"
d_stop
echo "."
;;
restart|force-reload)
echo -n "Restarting $DESC: $NAME"
d_stop
sleep 1
d_start
echo "."
;;
*)
echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
exit 1
;;
esac
exit 0
Voila je pense avoir tout mis. Je tiens a préciser que pendant le partionnement, le tuto qu'il y a sur le site dans mon fichier fstab, j'ai créer ceci
/dev/sda ext3 /home/alexis defaults 0 0
Tu n'as qu'un seul utilisateurs pour le moment, avant de vouloir mettre les 3 personnes je voulais tester avec un seul.