sudo groupadd 'xonotic' && sudo useradd -c 'Xonotic system account' -d '/var/lib/xonotic' -g 'xonotic' -m -r 'xonotic'
sudo dnf install 'git'
sudo firewall-cmd --add-port='26000'/'udp' --permanent && sudo firewall-cmd --reload
sudo git clone -b 'master' 'git://git.xonotic.org/xonotic/xonotic.git' '/srv/xonotic' && sudo chown -R 'xonotic':'xonotic' '/srv/xonotic' && sync
sudo su 'xonotic' -s '/usr/bin/bash'
cd '/srv/xonotic' && '/srv/xonotic/all' update -l 'best' && sync
cd '/srv/xonotic' && '/srv/xonotic/all' compile -r 'dedicated' && sync
sudo su 'xonotic' -s '/usr/bin/bash'
mkdir -p '/var/lib/xonotic/.xonotic/data' && cp '/srv/xonotic/server/server.cfg' '/var/lib/xonotic/.xonotic/data/server.cfg'
nano '/var/lib/xonotic/.xonotic/data/server.cfg'
sv_public 1 sv_status_privacy 1 hostname "RoE | Xonotic - Realm of Espionage Official InstaGib ($g_xonoticversion)" sv_motd "Welcome to the Realm of Espionage Xonotic server! InstaGib all day every day :p" maxplayers 16 g_maplist_shuffle 1 g_maplist_mostrecent_count 3 gametype dm skill 9 minplayers 3 g_maplist_check_waypoints 1 sv_maxidle 120 //sv_weaponstats_file http://www.xonotic.org/weaponbalance/ g_playerstats_uri "http://stats.xonotic.org/stats/submit" g_instagib 1 g_grappling_hook 1 g_jetpack 1
sudo -e '/etc/systemd/system/xonotic-dedi.service' && sudo systemctl daemon-reload && sudo systemctl enable 'xonotic-dedi' --now && sudo systemctl status 'xonotic-dedi' -l
[Unit] Description=Xonotic Dedicated Server Wants=network-online.target After=network-online.target [Service] User=xonotic Group=xonotic Type=simple WorkingDirectory=/srv/xonotic ExecStart='/srv/xonotic/all' run 'dedicated' Restart=always RestartSec=5 [Install] WantedBy=multi-user.target
sudo -e '/etc/systemd/system/xonotic-up.service'
[Service] User=xonotic Group=xonotic Type=oneshot WorkingDirectory=/srv/xonotic ExecStart='/srv/xonotic/all' clean --reclone ExecStart='/srv/xonotic/all' compile -r 'dedicated' ExecStart='/usr/bin/sync'
sudo -e '/etc/systemd/system/xonotic-up.timer' && sudo systemctl daemon-reload && sudo systemctl enable 'xonotic-up.timer' --now && sudo systemctl start 'xonotic-up' && sudo systemctl status 'xonotic-up' -l
[Unit] Description=Xonotic Git Updater and Compiler Wants=network-online.target After=network-online.target [Timer] OnCalendar=*-*-* 02:15:00 Persistent=true [Install] WantedBy=timers.target
sudo -e '/etc/systemd/system/xonotic-re.service'
[Service] Type=oneshot ExecStart='/usr/bin/systemctl' stop 'xonotic-dedi' ExecStart='/usr/bin/sync' ExecStart='/usr/bin/systemctl' start 'xonotic-dedi'
sudo -e '/etc/systemd/system/xonotic-re.timer' && sudo systemctl daemon-reload && sudo systemctl enable 'xonotic-re.timer' --now && sudo systemctl start 'xonotic-re' && sudo systemctl status 'xonotic-re' -l
[Unit] Description=Xonotic Dedicated Server Restarter Wants=network-online.target After=network-online.target [Timer] OnCalendar=*-*-* 02:30:00 Persistent=true [Install] WantedBy=timers.target