From c60c145accc2619fdb53f2d19fbcec93f92189e0 Mon Sep 17 00:00:00 2001 From: vlaborie Date: Mon, 24 Jul 2017 09:48:09 +0200 Subject: [PATCH] Unite systemd --- HowtoLog2mail.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/HowtoLog2mail.md b/HowtoLog2mail.md index 90084eb2..3a17d285 100644 --- a/HowtoLog2mail.md +++ b/HowtoLog2mail.md @@ -16,6 +16,24 @@ $ wget http://pub.evolix.net/stretch/log2mail_0.3.0-2_amd64.deb # dpkg -i log2mail_0.3.0-2_amd64.deb ~~~ +Ce paquet log2mail ne fournit pas encore d'unité systemd, on pourra créer l'unité suivante dans /etc/systemd/system/log2mail.service : + +~~~ +[Unit] +Description=Daemon watching logfiles and mailing lines matching patterns +After=network.target + +[Service] +Type=forking +ExecStart=/usr/sbin/log2mail -- -f /etc/log2mail/config +KillMode=control-group +Restart=always +User=log2mail +Group=adm + +[Install] +WantedBy=multi-user.target +~~~ ## Configuration