systemd Unit

Christian Rößner cr at sys4.de
Sat Aug 16 17:40:10 CEST 2014


Hi,

Am 16.08.2014 um 16:43 schrieb Luigi Rosa <lists at luigirosa.com>:

> I am trying to create a systemd unit file to run amavisd-new
> 
> amavisd starts and then exits without demonizing itself
> 
> See my file at the and of this message.
> 
> I have tried also with no success:
> * Type=forking instead of simple
> * ExecStart=/usr/local/sbin/amavisd
> * ExecStart=/usr/local/sbin/amavisd start
> 
> 
> 
> 
> [Unit]
> Description=Antispam
> After=network.target
> After=network.target
> 
> [Service]
> Type=simple
> Restart=always
> RestartSec=60
> ExecStart=/usr/bin/perl -T /usr/local/sbin/amavisd
> ExecStop=/usr/bin/perl -T /usr/local/sbin/amavisd stop
> TimeoutSec=60
> 
> [Install]
> WantedBy=multi-user.target

This one here is the unit that comes with Gentoo:

[Unit]
Description=Amavisd Daemon
Wants=postfix.service
Wants=spamassassin.service
Wants=clamd.service
After=network.target

[Service]
ExecStart=/usr/sbin/amavisd -c /etc/amavisd.conf foreground
ExecReload=/usr/sbin/amavisd -c /etc/amavisd.conf reload

[Install]
WantedBy=multi-user.target


-Christian Rößner

--
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64
Franziskanerstraße 15, 81669 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 495 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.amavis.org/pipermail/amavis-users/attachments/20140816/fbc31e2f/attachment.sig>


More information about the amavis-users mailing list