Skip to content

Instantly share code, notes, and snippets.

@pa-0
Forked from gene1wood/transmission-daemon
Created August 11, 2025 23:00
Show Gist options
  • Save pa-0/6818f479b4313052f7673ac58a0642a1 to your computer and use it in GitHub Desktop.
Save pa-0/6818f479b4313052f7673ac58a0642a1 to your computer and use it in GitHub Desktop.
transmission-daemon sysconfig file to enable binding to an interface
# /etc/sysconfig/transmission-daemon
INTERFACE=ppp0 # Set this to the interface you want the daemon to bind to
if /sbin/ifconfig $INTERFACE >>/dev/null 2>&1; then
BIND_ADDR="`/sbin/ifconfig $INTERFACE | awk '$1 == \"inet\" {print $2}' | awk -F: '{print $2}'`"
else
BIND_ADDR="127.0.0.1"
fi
# These are your standard daemon arguments
DAEMON_ARGS="--blocklist --auth --allowed \"127.*.*.*\" --logfile /var/log/transmission/transmission.log"
# This binds the daemon to the IP address of the interface $INTERFACE
DAEMON_ARGS="$DAEMON_ARGS --bind-address-ipv4 $BIND_ADDR"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment