Albirew/nyaa-pantsu
Archivé
1
0
Bifurcation 0
Ce dépôt a été archivé le 2022-05-07. Vous pouvez voir ses fichiers ou le cloner, mais pas ouvrir de ticket ou de demandes d'ajout, ni soumettre de changements.
nyaa-pantsu/deploy/ansible/roles/backup/templates/rtorrent.service.j2
tomleb d8b82b52e0 Distribute the database with daily backups
Daily cron job that dump the database, xz it, sign it with GPG,
create a torrent file and seed it with rtorrent.
2017-05-17 19:05:58 -04:00

17 lignes
559 o
Django/Jinja

[Unit]
Description=rTorrent
After=network.target
[Service]
Type=forking
KillMode=none
User={{ ansible_ssh_user }}
# FIXME Start-pre gives an 'Operation not supported error'
#ExecStartPre=/usr/bin/bash -c "if test -e %h/.rtorrent_session/rtorrent.lock && test -z `pidof rtorrent`; then rm -f %h/.rtorrent_session/rtorrent.lock; fi"
ExecStart=/usr/bin/screen -dmfa -S rtorrent /usr/bin/rtorrent
ExecStop=/usr/bin/bash -c "test `pidof rtorrent` && killall -w -s 2 /usr/bin/rtorrent"
WorkingDirectory=%h
Restart=on-failure
[Install]
WantedBy=multi-user.target