aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Runge <dave@sleepmap.de>2015-03-31 01:57:33 +0200
committerDavid Runge <dave@sleepmap.de>2015-03-31 01:57:33 +0200
commit567ea77ffd37c9ef6d520afa3ad24da342b46673 (patch)
tree3f7542f5c3b47a49867382a459737b3d22fcddfd
parent0ab686a15915a9a2a58d1cb414af4d1a9a05561b (diff)
downloaduenv-567ea77ffd37c9ef6d520afa3ad24da342b46673.tar.gz
uenv-567ea77ffd37c9ef6d520afa3ad24da342b46673.tar.bz2
uenv-567ea77ffd37c9ef6d520afa3ad24da342b46673.tar.xz
uenv-567ea77ffd37c9ef6d520afa3ad24da342b46673.zip
system/rtorrent@.service: Adding first version.
-rw-r--r--system/rtorrent@.service18
1 files changed, 18 insertions, 0 deletions
diff --git a/system/rtorrent@.service b/system/rtorrent@.service
new file mode 100644
index 0000000..b6b6b40
--- /dev/null
+++ b/system/rtorrent@.service
@@ -0,0 +1,18 @@
+[Unit]
+Description=rTorrent
+Requires=openvpn@ipredator.service
+
+[Service]
+Type=forking
+KillMode=control-group
+User=%i
+EnvironmentFile/etc/uenv/rtorrent@.conf
+ExecStartPre=/usr/bin/mkdir -p /home/%i/Downloads/rtorrent/tmp
+ExecStartPre=/usr/bin/mkdir -p /home/%i/Downloads/rtorrent/session
+ExecStart=/usr/bin/tmux -L rt new-session -s rt -n rtorrent -d rtorrent
+ExecStop=/usr/bin/tmux -L rt send-keys -t rt:rtorrent C-q
+WorkingDirectory=/home/%i/Downloads/
+Restart=on-failure
+
+[Install]
+WantedBy=default.target