Before you proceed! 1. make sure your Ubuntu server has ipv6 disabled, otherwise players cannot join through server list. (read below) 2. make sure you got root access 3. game should be downloaded inside "/root" folder like "/root/polyfield" -------------- UPDATE v0.7.5+ ----------------- the game folders and files are created next to game files: - /root/Polyfield.x86_64 >> game file - /root/editor >> editor maps folder - /root/ServerConfig.txt >> server config - /root/banned-users.txt >> banned users the game will migrate the files on first run. -------------- INSTALL GAME ------------------- you need to install these: apt-get install screen unzip libc6-i386 lib32stdc++6 install for 32bit: (Optional) apt-get install libncurses5:i386 download the game: wget https://polyfield.net/builds/Polyfield_v0.7.5_Linux_Update4.zip unzip the game: unzip Polyfield_v0.7.5_Linux_Update4.zip give it execute permission: chmod +x Polyfield_v0.7.5_Linux.x86_64 ---------------- GAME CONFIG ------------------ run the game once to create the folders: ./Polyfield_v0.7.5_Linux.x86_64 close the game after 1 min: Ctrl + C or Ctrl + Z check "ServerConfig.txt" file appears: ls Enter edit the config: nano ServerConfig.txt save: Ctrl + O Enter download manually if it doesn't appear: (or check your directories) wget https://polyfield.net/builds/ServerConfig.txt -------------- RUN SERVER -------------------- create a screen so you can close the terminal: screen -S test run the game in screen: ./Polyfield_v0.7.5_Linux.x86_64 detach from screen: Ctrl + A + D close the terminal. ----------------- ENJOY --------------------- later accessing the game: screen -r test see the running games: top close: Ctrl + C or Ctrl + Z --------- Download some good maps ----------- (Optional) move to the location: cd /root/editor remove all maps: rm -r * download back: wget https://polyfield.net/builds/Server_Maps.zip unzip: unzip Server_Maps.zip ----------------- BAN-LIST --------------------- users get banned for 90 days. server saves the ban list here: /root/banned-users.txt close the game before editing. ------------------ CRONJOB ------------------ (Optional) edit crontab: crontab -e restart every 2 hours: 0 */2 * * * pkill Polyfield ; ./Polyfield_v0.7.5_Linux.x86_64 & save: Ctrl + O Enter ---------------- DISABLE IPV6 ------------------ create a file: nano /usr/local/sbin/disable-ipv6.sh place these: /usr/sbin/sysctl -w net.ipv6.conf.all.disable_ipv6=1 /usr/sbin/sysctl -w net.ipv6.conf.default.disable_ipv6=1 /usr/sbin/sysctl -w net.ipv6.conf.lo.disable_ipv6=1 Ctrl + O + Enter >> Save Ctrl + X >> Exit give perm: chmod +x /usr/local/sbin/disable-ipv6.sh apply to cronjob: 0 * * * * /usr/local/sbin/disable-ipv6.sh apply by hand: /usr/local/sbin/disable-ipv6.sh check: (it should show nothing) ip -6 addr show ------------------ SYSTEMD ----------------- (Optional) (This will keep the app running if crashed) create file for auto-run service: sudo nano /etc/systemd/system/game.service copy & paste into the file: ########################################### [Unit] Description=Game Server After=network.target [Service] ExecStart=/root/Polyfield_v0.7.5_Linux.x86_64 Restart=always RestartSec=5 WorkingDirectory=/root User=root RestartForceExitStatus=0 #Environment=GAME_VAR=value [Install] WantedBy=multi-user.target ########################################### reload & start: sudo systemctl daemon-reload sudo systemctl enable game.service sudo systemctl start game.service check status: sudo systemctl status game.service see live logs: sudo journalctl -u game.service -f