aboutsummarylogtreecommitdiffstats
path: root/megasyncd.service
diff options
context:
space:
mode:
authorarchimede2016-12-11 01:37:10 +0800
committerarchimede2016-12-11 23:46:27 +0800
commitaa7c8b17b318d82e8d82d3af42d02493c4117ddf (patch)
tree9537e397e692cd996b6ca837f4bec6b4d09bcff0 /megasyncd.service
downloadaur-aa7c8b17b318d82e8d82d3af42d02493c4117ddf.tar.gz
initial commit
Diffstat (limited to 'megasyncd.service')
-rw-r--r--megasyncd.service16
1 files changed, 16 insertions, 0 deletions
diff --git a/megasyncd.service b/megasyncd.service
new file mode 100644
index 000000000000..30776cc9faa2
--- /dev/null
+++ b/megasyncd.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=Mega sync client
+After=local-fs.target network.target
+
+[Service]
+Type=simple
+EnvironmentFile=/etc/conf.d/megasync.conf
+ExecStart=/usr/bin/bash -c "cd $MEGA_WORK_DIR && /usr/local/bin/megasimplesync $MEGA_LOCAL_DIR $MEGA_REMOTE_DIR"
+ExecReload=/bin/kill -HUP $MAINPID
+KillMode=process
+Restart=on-failure
+RestartSec=30s
+
+[Install]
+WantedBy=multi-user.target
+