aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/systemd/README.systemd
diff options
context:
space:
mode:
authorBarak A. Pearlmutter <barak@pearlmutter.net>2021-11-23 10:47:03 +0000
committerMatthias Andree <matthias.andree@gmx.de>2021-11-27 12:39:28 +0100
commitda52ecef355c3cd57f8575b5c6459879fa3a5f52 (patch)
treeaf96a023c8a16bade2741759d947d9f0db49d8e5 /contrib/systemd/README.systemd
parentbc21a121248c5d9435b93736f64971472d9280cc (diff)
downloadfetchmail-da52ecef355c3cd57f8575b5c6459879fa3a5f52.tar.gz
fetchmail-da52ecef355c3cd57f8575b5c6459879fa3a5f52.tar.bz2
fetchmail-da52ecef355c3cd57f8575b5c6459879fa3a5f52.zip
Add systemd example and instructions.
Diffstat (limited to 'contrib/systemd/README.systemd')
-rw-r--r--contrib/systemd/README.systemd23
1 files changed, 23 insertions, 0 deletions
diff --git a/contrib/systemd/README.systemd b/contrib/systemd/README.systemd
new file mode 100644
index 00000000..fd7229a0
--- /dev/null
+++ b/contrib/systemd/README.systemd
@@ -0,0 +1,23 @@
+To run fetchmail as a systemd user service, for an individual user:
+
+(1) Configuration
+
+Set up your .fetchmailrc so that "fetchmail --nodetach" actually
+fetches your mail correctly.
+
+(2) Tell systemd to run it as a service
+
+Allow daemons to keep running after you log out (optional):
+$ sudo loginctl enable-linger $USERNAME
+
+Make the service available:
+$ systemctl --user enable fetchmail.service
+
+Actually turn it on:
+$ systemctl --user start fetchmail.service
+
+Monitor it, to check if it's okay:
+$ systemctl --user status fetchmail.service
+
+Monitor it harder:
+$ journalctl --user -xeu fetchmail.service