service_files/systemd/terraria.service

18 lines
418 B
SYSTEMD
Raw Permalink Normal View History

2024-12-18 10:51:48 -03:00
[Unit]
Description=terraria game server
Wants=network.target
PartOf=steam-tmux-master.service
After=steam-tmux-master.service
[Service]
Type=oneshot
WorkingDirectory=/home/steam/terraria
User=steam
Group=steam
RemainAfterExit=yes
ExecStart=/usr/bin/tmux new-session -s terraria -d "/home/steam/terraria/start-server.sh"
ExecStop=/usr/bin/tmux send-keys -t terraria "/exit" Enter
[Install]
WantedBy=multi-user.target