2022-08-11 08:39:56 -07:00
# Set an interface with IPv4 address to bind to:
method.insert = cfg.interface.bind, string|const|private, (cat,"wg0")
# Get IPv4 address of a given interface
method.insert = get_interface_ipv4_address, simple|private, "execute.capture=bash,-c,\"$cat=\\\"echo -n \$(ip -o -4 addr show \\\",$argument.0=,\\\" | grep -Po 'inet \\\\\\\\\\K[\\\\\\\\\\d.]+')\\\"\""
# The IP address the listening socket and outgoing connections is bound to. (bind)
schedule2 = set_bind_address, 0, 0, \
"branch=((cfg.interface.bind)), \
((network.bind_address.set,(get_interface_ipv4_address,(cfg.interface.bind))))"
2022-09-08 23:49:56 -07:00
# Port range to use for listening. (port_range)
network.port_range.set = @dhtPort@-@dhtPort@
# Enable/disable peer exchange for torrents that aren't marked private. Disabled by default. (peer_exchange)
protocol.pex.set = 1
# Set whether the client should try to connect to UDP trackers (It can cause various problems if it's enabled, if you experience any with this option enabled then disable it.)
trackers.use_udp.set = 1
# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off".
# For DHT to work, a session directory must be defined.
dht.mode.set = auto
2022-08-11 08:39:56 -07:00
dht.port.set = @dhtPort@
2022-09-08 23:49:56 -07:00
2022-09-15 22:31:46 -07:00
throttle.max_uploads.set = 100
throttle.max_uploads.global.set = 250
throttle.min_peers.normal.set = 1
throttle.max_peers.normal.set = 1024
throttle.min_peers.seed.set = 1
throttle.max_peers.seed.set = 1024
trackers.numwant.set = 80
2022-09-08 23:49:56 -07:00
# Adding public DHT servers for easy bootstrapping
schedule2 = dht_node_1, 5, 0, "dht.add_node=router.utorrent.com:6881"
schedule2 = dht_node_2, 5, 0, "dht.add_node=dht.transmissionbt.com:6881"
schedule2 = dht_node_3, 5, 0, "dht.add_node=router.bitcomet.com:6881"
schedule2 = dht_node_4, 5, 0, "dht.add_node=dht.aelitis.com:6881"
2022-08-11 08:39:56 -07:00
2022-08-10 21:08:10 -07:00
# Enable the default ratio group.
ratio.enable=
# Change the limits, the defaults should be sufficient.
ratio.min.set = 100
ratio.max.set = 300
ratio.upload.set = 20M
2022-08-11 19:19:42 -07:00
# To ensure world-readable results
2022-08-11 19:22:09 -07:00
system.umask.set = 0000
2022-08-11 19:19:42 -07:00
2022-08-10 21:08:10 -07:00
# Changing the command triggered when the ratio is reached.
# (the default is "d.try_close= ; d.ignore_commands.set=1")
method.set = group.seeding.ratio.command, "d.close= ; d.erase="
# Add new method to get finished dir (called get_finished_dir)
method.insert = d.get_finished_dir,simple,"cat=@finalDir@/,$d.custom1="
# Bind event "torrent has finished" to action "move to new directory based on label"
# method.set_key = event.download.finished,move_complete
# Modifies the event.download.finished event to also have a new “key”
# called “move_complete”. From what I understand, rTorrent executes all
# “keys” in an event whenever that event is fired. The
# event.download.finished event fires whenever a torrent has finished
# downloading. The stuff within the quotation marks is the new key’ s
# commands. Each command is separated by a semicolon (;).
# d.directory.set=$d.get_finished_dir=;
# d.directory.set sets the directory of the torrent in rTorrent’ s own
# information. It does not move the torrent, just means rTorrent will
# look in that directory from now on. $d.get_finished_dir just runs the
# get_finished_dir method preciously inserted; constructing a path name
# by combining [folder]/finished/ with whatever label was applied
# ($d.custom1 contains the label).
# execute=mkdir,-p,$d.get_finished_dir=;
# Gets the same path name and makes sure the directory actually exists.
# Mkdir is the standard *nix command for creating directories. -p means
# creating parent directories if needed and not complaining if directory
# already exists.
# execute=mv,-u,$d.base_path=,$d.get_finished_dir=
# Uses the same “execute” functionality as above to run the standard *nix
# mv command to move the torrent’ s files (whose location is stored in
# d.base_path) to, once again, the directory whose name was constructed
# by the get_finished_dir method.
method.set_key = event.download.finished,move_complete,"d.directory.set=$d.get_finished_dir=;execute=mkdir,-p,$d.get_finished_dir=;execute=mv,-u,$d.base_path=,$d.get_finished_dir="