Add systemd init script
mrash opened this issue · 3 comments
mrash commented
Add an init script for systems running systemd. This issue was reported by Robert Watson to the psad mailing list.
rathann commented
Here's a systemd unit I wrote for the Fedora package:
[Unit]
Description=The Port Scan Attack Detector (psad)
Documentation=man:psad(8) https://www.cipherdyne.org/psad/
[Service]
Type=forking
ExecStart=/usr/sbin/psad
ExecStop=/usr/sbin/psad --Kill
ExecReload=/usr/sbin/psad --HUP
PIDFile=/var/run/psad/psad.pid
[Install]
WantedBy=multi-user.target
Install it as /usr/lib/systemd/system/psad.service
. It could be improved by adding dependencies on either firewalld or iptables services, but it's a good start.
mrash commented
An initial version was added to psad-2.4.4, and I've also added your script in 430ded8 for psad-2.4.5.
rathann commented
Excellent, thank you!