extras/systemd/crashtest.service
author Vincent Tondellier <tonton+hg@team1664.org>
Sun, 27 Nov 2016 17:17:43 +0100
changeset 119 0a9171619fd3
parent 111 f827f3c50dcf
permissions -rw-r--r--
Use Mojo::Pg automatic json decoding instead of doing it manually

[Unit]
Description=CrashTest Web Service
Requires=network.target
After=network.target
ConditionPathExists=/etc/crashtest/crash_test.conf

[Service]
Type=forking
User=crashtest
RemainAfterExit=yes
ProtectSystem=full

Environment=MOJO_CONFIG=/etc/crashtest/crash_test.conf
EnvironmentFile=-/etc/default/crashtest

;PrivateTmp=yes
;JoinsNamespaceOf=

RuntimeDirectory=crashtest
RuntimeDirectoryMode=0755
PIDFile=/run/crashtest/hypnotoad.pid

WorkingDirectory=/var/lib/crashtest
ExecStart=/usr/bin/hypnotoad /usr/bin/CrashTest
ExecStop=/usr/bin/hypnotoad -s /usr/bin/CrashTest
ExecReload=/usr/bin/hypnotoad /usr/bin/CrashTest

[Install]
WantedBy=multi-user.target