Release
This commit is contained in:
36
sources/init/rtorrent
Normal file
36
sources/init/rtorrent
Normal file
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Dépendance : screen, killall et rtorrent
|
||||
### BEGIN INIT INFO
|
||||
# Provides: <username>-rtorrent
|
||||
# Required-Start: $syslog $network
|
||||
# Required-Stop: $syslog $network
|
||||
# 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
|
||||
|
||||
## Début configuration ##
|
||||
user="rtorrent"
|
||||
## Fin configuration ##
|
||||
|
||||
rt_start() {
|
||||
su --command="screen -dmS rtorrent rtorrent" "${user}"
|
||||
}
|
||||
|
||||
rt_stop() {
|
||||
killall --user "${user}" screen
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start) echo "Starting rtorrent..."; rt_start
|
||||
;;
|
||||
stop) echo "Stopping rtorrent..."; rt_stop
|
||||
;;
|
||||
restart) echo "Restart rtorrent..."; rt_stop; sleep 1; rt_start
|
||||
;;
|
||||
*) echo "Usage: $0 {start|stop|restart}"; exit 1
|
||||
;;
|
||||
esac
|
||||
exit 0
|
||||
27
sources/nginx/rutorrent.conf
Normal file
27
sources/nginx/rutorrent.conf
Normal file
@@ -0,0 +1,27 @@
|
||||
location PATHTOCHANGE {
|
||||
alias /var/www/rutorrent;
|
||||
|
||||
if ($scheme = http) {
|
||||
rewrite ^ https://$server_name$request_uri? permanent;
|
||||
}
|
||||
|
||||
client_max_body_size 10G;
|
||||
index index.html;
|
||||
try_files $uri $uri/ index.html;
|
||||
location ~ [^/]\.php(/|$) {
|
||||
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
|
||||
fastcgi_pass unix:/var/run/php5-fpm.sock;
|
||||
fastcgi_index index.html;
|
||||
fastcgi_param SCRIPT_FILENAME $request_filename;
|
||||
include fastcgi_params;
|
||||
}
|
||||
|
||||
include conf.d/yunohost_panel.conf.inc;
|
||||
|
||||
}
|
||||
|
||||
location PATHTOCHANGE/RPC2 {
|
||||
scgi_pass 127.0.0.1:5000;
|
||||
include scgi_params;
|
||||
scgi_param SCRIPT_NAME /RPC2;
|
||||
}
|
||||
13
sources/plugins/create/conf.php
Executable file
13
sources/plugins/create/conf.php
Executable file
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
// configuration parameters
|
||||
|
||||
$useExternal = 'buildtorrent'; // Valid choices:
|
||||
// false - use internal realization (may be too slow for large files)
|
||||
// "transmissioncli" - use program transmissioncli (see http://www.transmissionbt.com/)
|
||||
// "transmissioncreate" - use program transmissioncreate (see http://www.transmissionbt.com/)
|
||||
// "createtorrent" - use program createtorrent (see http://www.createtorrent.com)
|
||||
// "mktorrent" - use program createtorrent (see http://mktorrent.sourceforge.net)
|
||||
// "buildtorrent" - use program buildtorrent (see http://claudiusmaximus.goto10.org/cm/torrent.html)
|
||||
$pathToCreatetorrent = ''/usr/bin/buildtorrent'; // Something like /bin/createtorrent, or /bin/transmissioncli. If empty, program will be found in PATH.
|
||||
|
||||
$recentTrackersMaxCount = 15;
|
||||
29
sources/plugins/filemanager/conf.php
Normal file
29
sources/plugins/filemanager/conf.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
$fm['tempdir'] = '/tmp'; // path were to store temporary data ; must be writable
|
||||
$fm['mkdperm'] = 755; // default permission to set to new created directories
|
||||
|
||||
// set with fullpath to binary or leave empty
|
||||
$pathToExternals['rar'] = '/usr/bin/rar';
|
||||
$pathToExternals['zip'] = '/usr/bin/zip';
|
||||
$pathToExternals['unzip'] = '/usr/bin/unzip';
|
||||
$pathToExternals['tar'] = '/bin/tar';
|
||||
$pathToExternals['gzip'] = '/bin/gzip';
|
||||
$pathToExternals['bzip2'] = '/bin/bzip2';
|
||||
|
||||
|
||||
// archive mangling, see archiver man page before editing
|
||||
|
||||
$fm['archive']['types'] = array('rar', 'zip', 'tar', 'gzip', 'bzip2');
|
||||
|
||||
|
||||
|
||||
|
||||
$fm['archive']['compress'][0] = range(0, 5);
|
||||
$fm['archive']['compress'][1] = array('-0', '-1', '-9');
|
||||
$fm['archive']['compress'][2] = $fm['archive']['compress'][3] = $fm['archive']['compress'][4] = array(0);
|
||||
|
||||
|
||||
|
||||
|
||||
?>
|
||||
1402
sources/plugins/mobile/init.js
Normal file
1402
sources/plugins/mobile/init.js
Normal file
File diff suppressed because it is too large
Load Diff
20
sources/rtorrent/rtorrent.rc
Normal file
20
sources/rtorrent/rtorrent.rc
Normal file
@@ -0,0 +1,20 @@
|
||||
scgi_port = 127.0.0.1:5000
|
||||
encoding_list = UTF-8
|
||||
port_range = 45069-45069
|
||||
port_random = no
|
||||
check_hash = no
|
||||
directory = DATA_DIR/downloads
|
||||
session = DATA_DIR/.session
|
||||
encryption = allow_incoming, try_outgoing, enable_retry
|
||||
schedule = watch_directory,1,1,"load_start=DATA_DIR/watch/*.torrent"
|
||||
schedule = untied_directory,5,5,"stop_untied=DATA_DIR/watch/*.torrent"
|
||||
use_udp_trackers = yes
|
||||
dht = off
|
||||
peer_exchange = no
|
||||
min_peers = 40
|
||||
max_peers = 100
|
||||
min_peers_seed = 10
|
||||
max_peers_seed = 50
|
||||
max_uploads = 15
|
||||
execute = {sh,-c,/usr/bin/php /var/www/rutorrent/php/initplugins.php &}
|
||||
schedule = espace_disque_insuffisant,1,30,close_low_diskspace=500M
|
||||
64
sources/rutorrent/config.php
Executable file
64
sources/rutorrent/config.php
Executable file
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
// configuration parameters
|
||||
|
||||
// for snoopy client
|
||||
@define('HTTP_USER_AGENT', 'Mozilla/5.0 (Windows NT 6.0; WOW64; rv:12.0) Gecko/20100101 Firefox/12.0', true);
|
||||
@define('HTTP_TIME_OUT', 30, true); // in seconds
|
||||
@define('HTTP_USE_GZIP', true, true);
|
||||
$httpIP = null; // IP string. Or null for any.
|
||||
|
||||
@define('RPC_TIME_OUT', 5, true); // in seconds
|
||||
|
||||
@define('LOG_RPC_CALLS', false, true);
|
||||
@define('LOG_RPC_FAULTS', true, true);
|
||||
|
||||
// for php
|
||||
@define('PHP_USE_GZIP', false, true);
|
||||
@define('PHP_GZIP_LEVEL', 2, true);
|
||||
|
||||
$schedule_rand = 10; // rand for schedulers start, +0..X seconds
|
||||
|
||||
$do_diagnostic = true;
|
||||
$log_file = '/tmp/errors.log'; // path to log file (comment or leave blank to disable logging)
|
||||
|
||||
$saveUploadedTorrents = true; // Save uploaded torrents to profile/torrents directory or not
|
||||
$overwriteUploadedTorrents = false; // Overwrite existing uploaded torrents in profile/torrents directory or make unique name
|
||||
|
||||
$topDirectory = 'DATA_DIR/downloads'; // Upper available directory. Absolute path with trail slash.
|
||||
$forbidUserSettings = false;
|
||||
|
||||
$scgi_port = 5000;
|
||||
$scgi_host = "127.0.0.1";
|
||||
|
||||
// For web->rtorrent link through unix domain socket
|
||||
// (scgi_local in rtorrent conf file), change variables
|
||||
// above to something like this:
|
||||
//
|
||||
// $scgi_port = 0;
|
||||
// $scgi_host = "unix:///tmp/rpc.socket";
|
||||
|
||||
$XMLRPCMountPoint = "/RPC2"; // DO NOT DELETE THIS LINE!!! DO NOT COMMENT THIS LINE!!!
|
||||
|
||||
$pathToExternals = array(
|
||||
"php" => '', // Something like /usr/bin/php. If empty, will be found in PATH.
|
||||
"curl" => '/usr/bin/curl', // Something like /usr/bin/curl. If empty, will be found in PATH.
|
||||
"gzip" => '', // Something like /usr/bin/gzip. If empty, will be found in PATH.
|
||||
"id" => '', // Something like /usr/bin/id. If empty, will be found in PATH.
|
||||
"stat" => '', // Something like /usr/bin/stat. If empty, will be found in PATH.
|
||||
);
|
||||
|
||||
$localhosts = array( // list of local interfaces
|
||||
"127.0.0.1",
|
||||
"localhost",
|
||||
);
|
||||
|
||||
$profilePath = '../share'; // Path to user profiles
|
||||
$profileMask = 0777; // Mask for files and directory creation in user profiles.
|
||||
// Both Webserver and rtorrent users must have read-write access to it.
|
||||
// For example, if Webserver and rtorrent users are in the same group then the value may be 0770.
|
||||
|
||||
$tempDirectory = null; // Temp directory. Absolute path with trail slash. If null, then autodetect will be used.
|
||||
|
||||
$canUseXSendFile = true; // Use X-Sendfile feature if it exist
|
||||
|
||||
$locale = "UTF8";
|
||||
Reference in New Issue
Block a user