Last active
November 13, 2017 12:01
-
-
Save mche/8e04aaae25aa1bdb696cade61166cf3d to your computer and use it in GitHub Desktop.
systemd for hypnotoad perl Mojolicious
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Mojolicious hypnotoad | |
After=postgresql.service | |
[Service] | |
Type=forking | |
PIDFile=/home/guest/hypnotoad.pid | |
WorkingDirectory=/home/guest | |
#User= | |
#Group= | |
Environment= | |
#OOMScoreAdjust=-200 | |
ExecStart=/bin/su -c 'perlbrew use perl-5.26.1 && hypnotoad script.pl ' - guest | |
ExecStop=/bin/su -c 'perlbrew use perl-5.26.1 && hypnotoad -s script.pl ' - guest | |
ExecReload=/bin/su -c 'perlbrew use perl-5.26.1 && hypnotoad script.pl ' - guest | |
#ExecReload=/bin/kill -USR2 $PIDFile | |
TimeoutSec=120 | |
#Restart=always | |
#RemainAfterExit=on | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment