background image
Game Servers 380 7 Days to Die 4 Abiotic Factor 2 Aloft 2 alt:V 2 Americas Army Proving Grounds 2 Among Us 2 Archean 2 ARK Survival Ascended 6 ARK Survival Evolved 3 Arma 3 3 Arma Reforger 2 Aska 2 AssaultCube 2 Assetto Corsa 3 Astro Colony 2 Astroneer 2 Automobilista 2 2 Avorion 2 Banana Shooter 2 Barotrauma 3 BATTALION Legacy 2 BeamNG.drive (BeamMP) 2 Black Mesa 2 Brickadia 2 Call of Duty 2 Citadel: Forged with Fire 2 ClassiCube 2 Clone Hero 2 Colony Survival 2 Conan Exiles 4 Contagion 2 Core Keeper 2 Counter-Strike 2 3 Craftopia 2 CryoFall 2 CS2D 2 Cube 2: Sauerbraten 2 Cubic Odyssey 2 DayZ 4 DDNet 2 DDRaceNetwork 2 Dead Matter 2 Dont Starve Together 4 Eco 2 Empyrion Galactic Survival 2 Enshrouded 3 Escape from Tarkov 2 Euro Truck Simulator 2 2 Factorio 2 Farming Simulator 25 2 Fistful of Frags 2 FiveM 3 FortressCraft Evolved 2 Foundry 2 Foundry VTT 2 Frozen Flame 2 FTL Tachyon 2 Garrys Mod 3 Ground Branch 2 Half-Life 2 Deathmatch 2 Hogwarp 2 Holdfast: Nations at War 2 HumanitZ 2 Hurtworld 2 Hytale 1 Icarus 2 Insurgency Sandstorm 2 IOSoccer 2 Just Cause 3 Multiplayer 2 Kerbal Space Program 2 Killing Floor 2 3 LeagueSandbox 2 Left 4 Dead 2 Left 4 Dead 2 3 Longvinter 2 Los Angeles Crimes 2 Medal of Honor 2 Midnight Ghost Hunt 2 Mindustry 2 Minecraft 4 Minetest 2 Modiverse 2 Mordhau 3 Mount & Blade II: Bannerlord 2 Myth of Empires 2 Nazi Zombies Portable 2 Necesse 2 NeosVR 2 Neverwinter Nights EE 2 Night of the Dead 2 Nightingale 2 No Love Lost 2 No More Room in Hell 2 No One Survived 2 Nova-Life Amboise 2 Nuclear Option 2 Onset 2 Open Fortress 2 OpenArena 2 OpenRA 2 OpenRCT2 2 OpenTTD 2 Operation Harsh Doorstop 2 Palworld 3 Path of Titans 2 Pavlov VR 3 PixARK 2 Plains of Pain 2 Portal Knights 2 Post Scriptum 2 Project Zomboid 8 Puck 2 Quake Live 2 R5Reloaded 2 RedM 2 Renown 2 Resonite 2 Return to Moria 2 Rimworld Together 2 Rising World 2 Risk of Rain 2 1 Rust 4 Satisfactory 1 SCP Secret Laboratory 3 SCUM 2 Smalland 2 Solace Crafting 2 Soldat 2 Soldat 2 2 Sonic Robo Blast 2 2 Sons of the Forest 2 Soulmask 2 SourceCoop 2 Space Engineers 3 Space Station 14 2 Squad 3 Starbound 3 StarMade 2 Stationeers 2 Stormworks 2 Subnautica Nitrox 2 Sunkenland 2 SuperTuxKart 2 Sven Co-op 2 Swords 'n Magic and Stuff 2 Team Fortress 2 3 Teeworlds 2 Terraria 3 TerraTech Worlds 2 TF2 Classified 2 The Forest 3 The Front 2 The Isle 2 Tower Unite 2 Trackmania 2 Unturned 4 Urban Terror 2 V Rising 3 Valheim 3 VEIN 2 Veloren 2 Vintage Story 3 Voyagers of Nera 2 Wolfenstein: Enemy Territory 2 Wreckfest 2 Wurm Unlimited 2 Xonotic 2 Zandronum 2 Getting Started 2 Network & Connectivity 1 Server Management 2
Kategorier

Foundry Server Setup Guide

foundry setup config factory-building 0 tyckte att detta var hjälpsamt

This guide covers how to set up your Foundry dedicated server on Legion Hosting, configure startup variables, edit the server settings file, set up world generation, connect to your server, and manage saves and backups. Foundry is a voxel-based factory-building game where players mine resources, build automated production lines, and expand massive factories across a procedurally generated world. For admin controls, player management, and troubleshooting, see Foundry Admin and Server Management.

Note: Foundry dedicated servers run independently from the in-game hosting option. A dedicated server keeps your factory world online 24/7 so players can continue building and automating without the host needing to be present.

1. First Start

  1. Log in to GPanel and select your Foundry server.
  2. Go to the Startup tab and review the configurable variables (see the table in Section 2).
  3. Set SERVER_NAME to a name for your server. This appears in the Steam server browser.
  4. Set SRV_PW if you want to restrict access. Leave it blank for a public server.
  5. Optionally set a MAP_SEED to control world generation. Leave blank for a random seed.
  6. Return to the Console tab and click Start.
  7. Wait for the console to confirm the server has started. The first launch may take a couple of minutes as the server generates the world and creates initial configuration files.
First start generates config files. If you need to edit App.cfg or other configuration files, start the server once, let it finish loading, then stop it before editing. The files will not exist until the first run.

2. GPanel Startup Variables

The following variables are available in the GPanel Startup tab. These are passed to the server on each start.

Variable Required Description
SERVER_NAME Yes The name displayed in the Steam server browser.
SRV_PW No Optional password players must enter to join. Leave blank for a public server.
MAX_PLAYERS No Maximum number of concurrent players. Default is 32.
MAP_SEED No World generation seed number. Use the same seed to recreate identical terrain. Leave blank for a random world.
WORLD_NAME No The name of the world/save folder. Default is MyFoundry. Changing this creates a new world.
PUBLIC_SERVER No Whether the server appears in the Steam server browser. Set to true or false. Default is true.

3. Server Configuration File

For advanced settings beyond what the startup variables offer, you can edit the server configuration file directly. Stop your server before making changes.

File Location

App.cfg

Open this file using the Files tab in GPanel or connect via SFTP. The file uses a simple key=value format with one setting per line. If the file does not exist, start and stop the server once to generate it.

Always stop your server before editing configuration files. The server reads App.cfg on startup. Changes made while the server is running will not take effect until the next restart.

Key Settings in App.cfg

Setting Default Description
server_name My Server Server name shown in the Steam server browser.
server_password (empty) Password required to join the server. Empty means public.
server_world_name MyFoundry The world/save folder name. Each unique name creates a separate world with its own save data.
server_max_players 32 Maximum concurrent players allowed on the server.
server_is_public true Controls whether the server is listed in the Steam server browser.
server_port 3724 Game port. This is managed by GPanel -- do not change it unless instructed by support.
server_query_port 27015 Steam query port used for server browser listings. Managed by GPanel.
map_seed (random) Seed number for procedural world generation. Use any integer value. The same seed always produces the same terrain layout.
autosave_interval 300 Auto-save interval in seconds. Default is 300 (5 minutes). Set to 0 to disable auto-save.
pause_server_when_empty true Pauses the game world when no players are connected. Set to false to keep the factory running 24/7.

Example Configuration

server_name=My Legion Factory
server_password=
server_world_name=MyFoundry
server_max_players=16
server_is_public=true
server_port=3724
server_query_port=27015
map_seed=48293175
autosave_interval=300
pause_server_when_empty=true
Do not change the port values. The server_port and server_query_port are assigned by GPanel and must match your allocated ports. Changing them will prevent players from connecting and the server from appearing in the browser.

4. World Generation

Foundry uses procedural world generation to create its voxel terrain. The world is generated from a seed number, which determines the layout of terrain, ore deposits, and biomes.

Map Seed

  • Set the map_seed value in App.cfg or the MAP_SEED startup variable to any integer.
  • Using the same seed always produces the same world layout, which is useful if you want to share a specific world with others or recreate a world after a reset.
  • Leave the seed blank or omit it entirely to let the server generate a random world.
  • The seed only affects initial world generation. Changing the seed on an existing world has no effect -- you must create a new world (change server_world_name) for a new seed to take effect.

World Name and Multiple Worlds

The server_world_name setting determines which save folder the server uses. You can maintain multiple worlds by switching between different world names:

  • Each unique server_world_name creates a separate world with its own save data, factory state, and player progress.
  • To switch worlds, stop the server, change the server_world_name in App.cfg, and restart.
  • Previous worlds are preserved and can be loaded again by switching back to their name.

Pause When Empty

The pause_server_when_empty option controls whether your factory continues operating when no players are online:

  • true (default) -- The world pauses when all players disconnect. Factories stop producing, resources stop being consumed. Good for saving server resources and keeping the game state predictable.
  • false -- The factory keeps running 24/7. Production lines continue, resources accumulate, and the world progresses even when nobody is playing. Can increase server resource usage.

5. How to Connect

Option A -- Steam Server Browser

  1. Launch Foundry.
  2. From the main menu, select Multiplayer.
  3. Click Join Game to open the server browser.
  4. Use the search bar to find your server by name.
  5. Select your server and click Join. Enter the server password if one is set.
It may take a few minutes for a newly started server to appear in the browser. If your server does not show up, try refreshing the list or connecting directly by IP.

Option B -- Direct Connect

  1. Launch Foundry.
  2. From the main menu, select Multiplayer.
  3. Choose the Direct Connect option.
  4. Enter your server's IP address and port from GPanel's Network tab:
    <your-server-ip>:<port>
  5. Enter the server password if prompted and click Connect.
Connection issues? Verify your server is running in GPanel, check that you are using the correct IP and port from the Network tab, and ensure the server password matches. Ports are randomly assigned unless you have a private IP. See How to Find Your Server IP and Port for help locating your connection details.

6. Save Management

Auto-Save

The server auto-saves at the interval specified by autosave_interval in App.cfg (default: every 300 seconds / 5 minutes). Foundry auto-saves are non-intrusive and do not cause noticeable lag for most factory sizes.

Save File Location

Save files are stored on the server at the path specified by server_persistent_data_override_folder in App.cfg. The default path is:

serverfiles/

This directory contains the full world state including terrain modifications, placed structures, factory machines, conveyor belts, and player inventories.

Manual Backups via SFTP

  1. Stop the server from GPanel to ensure all data is written to disk.
  2. Connect to your server via SFTP. See How to Upload Files via SFTP for instructions.
  3. Download the entire save directory for your world (e.g., serverfiles/).
  4. Store the backup in a safe location on your computer.
Back up regularly. Large factories with many machines and conveyor belts represent significant building effort. Regular backups protect against save corruption, accidental world resets, or unwanted changes by other players.

Restoring a Save

  1. Stop the server from GPanel.
  2. Connect via SFTP and navigate to the serverfiles/ directory.
  3. Upload your backed-up world directory, replacing the existing one.
  4. Ensure the folder name matches the server_world_name in App.cfg.
  5. Start the server from GPanel. The server will load the restored save.

7. Performance Tips

Foundry is a factory-building game, and server performance is directly affected by factory complexity. Keep these tips in mind as your factory grows:

  • Factory complexity: Large numbers of machines, conveyor belts, and logistics networks increase server tick load. If you notice lag, consider consolidating or optimizing production chains.
  • Chunk loading: The server processes all loaded chunks. More active factory areas spread across the map means more chunks to simulate. Keeping your factory compact reduces the number of chunks the server must track.
  • Player count: More connected players means more chunks loaded around each player. If performance degrades with many players, consider reducing server_max_players.
  • Auto-save frequency: Very frequent auto-saves (under 60 seconds) on large worlds can cause periodic hitches. The default 300 seconds is usually fine, but you can increase it if needed.
  • Pause when empty: Enabling pause_server_when_empty=true prevents unnecessary simulation when nobody is playing, which helps maintain consistent performance during active play sessions.
Tip: If your factory has grown very large and you are experiencing persistent lag, open a support ticket to discuss upgrading your server plan for additional resources.

Related Articles

Need Help?

If you run into issues with your Foundry server that are not covered here, open a support ticket and include your server IP, a description of the problem, and any relevant error messages from the GPanel console.


Var denna artikel hjälpsam?

Ready to Get Started?

The servers are booted, select your plan and become our latest satisfied client.