Bug#772931: pokerth-server: supporting systemd and System V

Markus Koschany apo at gambaru.de
Fri Mar 20 09:52:08 UTC 2015


On Fri, 12 Dec 2014 10:51:04 +0100 Markus Koschany <apo at gambaru.de> wrote:
[...]
> It would be nice if pokerth-server provided a systemd service file and
> a System V init script, so that the server could be conveniently
> monitored and started as a daemon.

The following systemd service file works for me. It is important to set
Type=forking and to specify the PIDFile location. Due to bug

https://bugs.debian.org/772929

you have to symlink the executable and the data directory into the same
working directory. Now only a system-wide pokerth user is missing which
could be created in postinst.

[Unit]
Description=PokerTH multiplayer server
Documentation=man:pokerth_server(6)
After=network.target

[Service]
Type=forking
Restart=on-failure
User=pokerth
ExecStart=/var/games/pokerth/pokerth_server -p /run/pokerth.pid
PIDFile=/run/pokerth.pid

[Install]
WantedBy=multi-user.target

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 949 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-games-devel/attachments/20150320/feb3efe5/attachment-0001.sig>


More information about the Pkg-games-devel mailing list