Add a systemd unit file using the latest "foreground portal" options

This commit is contained in:
friarzen 2018-09-29 20:19:54 +00:00
parent 5d2e30cf2a
commit ac8e125106

34
bin/unix/evennia.service Normal file
View file

@ -0,0 +1,34 @@
# Evennia systemd unit script
#
# Copy this to /usr/lib/systemd/system/ and Edit the paths to match your game.
#
# Then, register with systemd using:
#
# sudo systemctl daemon-reload
# sudo systemctl enable evennia.service
#
[Unit]
Description=Evennia Server
[Service]
Type=simple
#
# Change this to the user the game should run as.
# Don't run this as root. Please, I beg you.
#
User=your-user
#
# The command to start Evennia as a Systemd service. NOTE: These must be absolute paths.
# Replace /your/path/to with whatever is appropriate.
#
ExecStart=/your/path/to/pyenv/bin/python /your/path/to/evennia/bin/unix/evennia ipstart --gamedir /your/path/to/mygame
# restart on all failures, wait 3 seconds before doing so.
Restart=on-failure
RestartSec=3
[Install]
WantedBy=default.target