service_files/systemd/factorio.service

18 lines
416 B
SYSTEMD
Raw Permalink Normal View History

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