Skip to content

Instantly share code, notes, and snippets.

@rraallvv
Created November 4, 2018 17:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rraallvv/019ba0675c6e9ffdb1c6809eb2fe09c2 to your computer and use it in GitHub Desktop.
Save rraallvv/019ba0675c6e9ffdb1c6809eb2fe09c2 to your computer and use it in GitHub Desktop.
rTorrent service unit
[Unit]
Description=rTorrent daemon
After=network.target
[Service]
Type=forking
KillMode=none
User=myuser
Group=myuser
#CPUQuota=
#MemoryLimit=
#IOReadIOPSMax=
#IOWriteIOPSMax=
ExecStart=/usr/bin/screen -dmfa -S rtorrent /usr/bin/rtorrent
ExecStop=/usr/bin/killall -w -s 2 /usr/bin/rtorrent
WorkingDirectory=/home/myuser
#Restart=on-failure
#RestartSec=5
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment