2019-04-12 18:01:35 +00:00
|
|
|
[Unit]
|
|
|
|
Description=autocat3 Service
|
|
|
|
After=network.target
|
|
|
|
|
|
|
|
[Service]
|
|
|
|
User=autocat
|
|
|
|
Type=simple
|
2019-04-30 19:31:33 +00:00
|
|
|
RuntimeDirectory=autocat
|
2019-04-12 18:01:35 +00:00
|
|
|
WorkingDirectory=/var/lib/autocat/autocat3
|
2020-01-05 03:29:55 +00:00
|
|
|
ExecStartPre=-/usr/bin/mkdir -p /var/run/autocat ; -/usr/bin/curl -o /var/lib/autocat/menu.html https://raw.githubusercontent.com/gbnewby/gutenbergsite/master/_includes/menu.html
|
2019-10-10 16:36:41 +00:00
|
|
|
ExecStart=/usr/local/bin/pipenv run python CherryPyApp.py
|
|
|
|
#
|
|
|
|
# These next lines are for auto-restart. See: man systemd.service
|
|
|
|
Type=simple
|
2019-10-12 01:27:53 +00:00
|
|
|
PIDFile=/var/run/autocat/autocat3.pid
|
2019-10-10 16:36:41 +00:00
|
|
|
RemainAfterExit=no
|
|
|
|
Restart=on-failure
|
|
|
|
RestartSec=5s
|
|
|
|
TimeStartSec=5s
|
2019-04-12 18:01:35 +00:00
|
|
|
|
|
|
|
[Install]
|
2019-07-08 13:44:07 +00:00
|
|
|
WantedBy=multi-user.target
|