Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
I made a game server startup script like this:
Create a startup script
[email protected]:~$ nano ins-ds.sh
#!/bin/sh
cd /home/steam/ins-ds
prog="sudo -u steam ./srcds_run -cfg server.cfg -port 27015 +map market_coop -workshop"
${prog}
Make it executable
[email protected]:~$ chmod +x ins-ds.sh
Create an autostart service on server startup
[email protected]:~$ sudo nano /lib/ systemd/system/ins
[Unit]
Description=Insurgency Server
After=multi-user.target
[Service]
Type=idle
ExecStart=/home/steam/ins-ds.sh
[Install]
WantedBy=multi-user.target
edit launch rights
[email protected]:~$ sudo chmod 644 /lib/systemd/system/ins
Update configuration and enable script autorun
[email protected]:~$ sudo systemctl daemon-reload
[email protected]:~$ sudo systemctl enable ins
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question