Advertisement
Guest User

How to set up a factorio headless server

a guest
Mar 4th, 2019
3,599
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1. Windows:
  2. 1. Download the zip Folder of the newest version
  3. 2. Generate Map if you need to:
  4. a. Copy & Rename data\map-gen-settings and data\map-settings (remove .example)
  5. b. Edit files
  6. c. run cmd in the root of the folder
  7. d. bin\x64\factorio.exe --create SAVE-LOCATION.zip --map-gen-settings FILE.json --map-settings FILE.json
  8. 3. Copy & rename & Edit data\server-settings
  9. 4. Create batch script for starting the server: bin\x64\factorio.exe --start-server saves\server.zip --server-settings data\server-settings.json --bind 192.168.178.119 [ENTER] pause
  10. 5. done
  11.  
  12. Linux (confirmed on ubuntu 18.10)
  13.  
  14. 1. DOWNLOAD FACTORIO
  15. 2. sudo mkdir /srv/FactorioServer/
  16. 3. sudo chown user /srv/FactorioServer/ (instead of user use your username)
  17. 4. cd /srv/FactorioServer/
  18. 5. wget https://factorio.com/get-download/0.16.51/headless/linux64 (get URL of the latest headless version)
  19. 6. tar -xJf linux64 (linux64 is the filename)
  20. 7. rm linux64
  21.  
  22. 8. CREATION OF SAVEGAME
  23. 9. cd factorio/data
  24. 10. Edit map-gen-settings and map-settings with nano and save without .example
  25. 11. Cd ..
  26. 12. Mkdir saves
  27. 13. bin/x64/factorio --create saves/server.zip --map-gen-settings data/map-gen-settings.json --map-settings data/map-settings.json
  28.  
  29. 14. CONFIGURING SERVER
  30. 15. cd data
  31. 16. edit server-settings with nano and save without .example
  32. 17. cd ..
  33. 18. upload mods using filezilla or winSCP if you want (copy the entire mods folder of your normal game install)
  34. 19. bin/x64/factorio --start-server saves/server.zip --server-settings data/server-settings.json
  35.  
  36. 20. START AND STOP SCRIPTS
  37. 21. nano run.sh
  38. 22. nohup bin/x64/factorio --start-server saves/server.zip --server-settings data/server-settings.json &
  39. 23. chmod +x run.sh
  40. 24. ./run.sh
  41. 25. Nano stop.sh
  42. 26. pkill factorio
  43. 27. Chmod +x stop.sh
  44. 28. ./stop.sh
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement