aboutsummaryrefslogtreecommitdiffstats
path: root/systemd/wa-daemon@.service
diff options
context:
space:
mode:
Diffstat (limited to 'systemd/wa-daemon@.service')
-rw-r--r--systemd/wa-daemon@.service15
1 files changed, 15 insertions, 0 deletions
diff --git a/systemd/wa-daemon@.service b/systemd/wa-daemon@.service
new file mode 100644
index 0000000..4568ad0
--- /dev/null
+++ b/systemd/wa-daemon@.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=wa-cli: WhatsApp Web session (account %i)
+After=network-online.target
+Wants=network-online.target
+
+[Service]
+Type=simple
+ExecStart=%h/.local/bin/wa daemon start --foreground --account %i
+# If WhatsApp Web disconnects or Chrome dies, the daemon exits with 1 and is restarted.
+Restart=on-failure
+RestartSec=15
+TimeoutStopSec=30
+
+[Install]
+WantedBy=default.target