# HG changeset patch # User Alexander Medvedev # Date 1307848190 0 # Node ID d9c492bef43b4d8a57cfc329271e66cc5e284184 # Parent e18a6d4e2d71e034572989b43870e34e08382990 Fix: add transmission-daemon init files diff -r e18a6d4e2d71 -r d9c492bef43b transmission-daemon/stuff/settings.json --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/transmission-daemon/stuff/settings.json Sun Jun 12 03:09:50 2011 +0000 @@ -0,0 +1,65 @@ +{ + "alt-speed-down": 50, + "alt-speed-enabled": false, + "alt-speed-time-begin": 540, + "alt-speed-time-day": 127, + "alt-speed-time-enabled": false, + "alt-speed-time-end": 1020, + "alt-speed-up": 50, + "bind-address-ipv4": "0.0.0.0", + "bind-address-ipv6": "::", + "blocklist-enabled": false, + "blocklist-url": "http://www.example.com/blocklist", + "cache-size-mb": 32, + "dht-enabled": true, + "download-dir": "/mnt/data/downloads", + "download-limit": 100, + "download-limit-enabled": 0, + "encryption": 1, + "idle-seeding-limit": 30, + "idle-seeding-limit-enabled": false, + "incomplete-dir": "/root/Downloads", + "incomplete-dir-enabled": false, + "lpd-enabled": true, + "max-peers-global": 35, + "message-level": 2, + "open-file-limit": 32, + "peer-congestion-algorithm": "", + "peer-limit-global": 150, + "peer-limit-per-torrent": 60, + "peer-port": 51413, + "peer-port-random-high": 65535, + "peer-port-random-low": 49152, + "peer-port-random-on-start": false, + "peer-socket-tos": "default", + "pex-enabled": true, + "pidfile": "/var/run/transmission-daemon.pid", + "port-forwarding-enabled": true, + "preallocation": 1, + "prefetch-enabled": 1, + "ratio-limit": 2, + "ratio-limit-enabled": false, + "rename-partial-files": true, + "rpc-authentication-required": true, + "rpc-bind-address": "0.0.0.0", + "rpc-enabled": true, + "rpc-password": "{9aebfab2dedb060801e37b93e475042635dd8d2cNtxckwS7", + "rpc-port": 9091, + "rpc-url": "/transmission/", + "rpc-username": "tux", + "rpc-whitelist": "*", + "rpc-whitelist-enabled": true, + "script-torrent-done-enabled": false, + "script-torrent-done-filename": "", + "speed-limit-down": 100, + "speed-limit-down-enabled": false, + "speed-limit-up": 100, + "speed-limit-up-enabled": false, + "start-added-torrents": true, + "trash-original-torrent-files": false, + "umask": 18, + "upload-limit": 200, + "upload-limit-enabled": 0, + "upload-slots-per-torrent": 14, + "utp-enabled": false +} diff -r e18a6d4e2d71 -r d9c492bef43b transmission-daemon/stuff/transmission-daemon --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/transmission-daemon/stuff/transmission-daemon Sun Jun 12 03:09:50 2011 +0000 @@ -0,0 +1,57 @@ +#!/bin/sh +# /etc/init.d/transmission-daemon: Start, stop and restart transmission daemon on SliTaz, at boot +# time or with the command line. +# +# To start daemon at boot time, just put the right name in the $RUN_DAEMONS +# variable of /etc/rcS.conf and configure options with /etc/daemons.conf. +# +. /etc/init.d/rc.functions +. /etc/daemons.conf + +NAME=Transmission +DESC="transmission daemon" +DAEMON=/usr/bin/transmission-daemon +OPTIONS="-g /var/transmission-daemon/ -x /var/run/transmission-daemon.pid" +PIDFILE=/var/run/transmission-daemon.pid + +case "$1" in + start) + if active_pidfile $PIDFILE transmission-daemon ; then + echo "$NAME already running." + exit 1 + fi + echo -n "Starting $DESC: $NAME... " + $DAEMON $OPTIONS + status + ;; + stop) + if ! active_pidfile $PIDFILE transmission-daemon ; then + echo "$NAME is not running." + exit 1 + fi + echo -n "Stopping $DESC: $NAME... " + killall transmission-daemon + rm $PIDFILE + status + ;; + restart) + if ! active_pidfile $PIDFILE transmission-daemon ; then + echo "$NAME is not running." + exit 1 + fi + echo -n "Restarting $DESC: $NAME... " + killall transmission-daemon + rm $PIDFILE + sleep 2 + $DAEMON $OPTIONS + status + ;; + *) + echo "" + echo -e "\033[1mUsage:\033[0m /etc/init.d/`basename $0` [start|stop|restart]" + echo "" + exit 1 + ;; +esac + +exit 0