-
Notifications
You must be signed in to change notification settings - Fork 140
Installation and Usage
knoxfighter edited this page Nov 6, 2023
·
7 revisions
-
Pull the Docker container from Docker Hub using the pull command
docker pull ofsm/ofsm:latest
-
Now you can start the container by running:
docker run --name ofsm -d -p 80:80 -p 34197:34197/udp ofsm/ofsm:latest
- Download the latest release
- Download the Factorio Standalone server and install to a known directory.
- Run the server binary file, use the --dir flag to point the management server to your Factorio installation. If you are using the steam installation, point FSM to the steam directory.
./factorio-server-manager --dir /home/user/.factorio
./factorio-server-manager --dir /home/user/.steam/steam/steamapps/common/Factorio
- Visit localhost:8080 in your web browser.
- Download the latest release
- Download the Factorio Standalone server and install to a known directory.
- Run the server binary file via cmd or Powershell, use the --dir flag to point the management server to your Factorio installation.
.\factorio-server-manager --dir C:/Users/username/Factorio
- Visit localhost:8080 in your web browser.
Run the UI server and specify the directory of your Factorio server installation and the interface to run the HTTP server on. Edit the conf.json file with your desired credentials for authentication.
Usage of ./factorio-server-manager:
--bin string
Location of Factorio Server binary file (default "bin/x64/factorio")
--conf string
Specify location of Factorio Server Manager config file. (default "./conf.json")
--config string
Specify location of Factorio config.ini file (default "config/config.ini")
--dir string
Specify location of Factorio directory. (default "./")
--host string
Specify IP for webserver to listen on. (default "0.0.0.0")
--max-upload int
Maximum filesize for uploaded files (default 20MB). (default 20971520)
--port string
Specify a port for the server. (default "8080")
--glibc-custom string
Specify if custom glibc is used (default false) [true/false]
--glibc-loc string
Path to the glibc ld.so file (default "/opt/glibc-2.18/lib/ld-2.18.so")
--glibc-lib-loc
Path to the glibc lib folder (default "/opt/glibc-2.18/lib")
--autostart
Autostarts Factorio Server when FSM is starting. Default false [true/false]
(If no IP and/or port provided at startup, it will bind the factorio server to all interfaces
and set the server port to the default 34197, always loads latest save)
Example:
./factorio-server-manager --dir /home/user/.factorio --host 10.0.0.1
Custom glibc example:
./factorio-server-manager --dir /home/user/.factorio --host 10.0.0.1 --glibc-custom true --glibc-loc /opt/glibc-2.18/lib/ld-2.18.so --glibc-lib-loc /opt/glibc-2.18/lib
All fields for conf.json:
- factorio_dir string
- saves_dir string
- basemod_dir string
- mods_dir string
- mod_pack_dir string
- config_file string
- config_directory sring
- logfile string
- factorio_binary string
- rcon_pass string
- factorio_credentials_file string
- factorio_ip string
- server_ip string
- server_port string
- max_upload_size int64
- database_file string
- sq_lite_database_file string
- cookie_encryption_key string
- settings_file string
- log_file string
- console_cache_size int
- secure bool | default: `true`
Set this to `false`, if you are running without ssl/tls.
Settings can be defined in Environment variables, in the conf.json or as flags. Each variant overrides the previous one, in the order:
- Default
- Environment
- conf.json
- flag
Environment | conf.json | flag | Default | Description |
---|---|---|---|---|
FSM_CONF |
--conf |
./conf.json |
Specify location of Factorio Server Manager config file (relative to the server manager). | |
FSM_DIR |
factorio_dir |
--dir |
./ |
Path to factorio root (relative to the server manager). |
FSM_SERVER_IP |
server_ip |
--host |
0.0.0.0 |
IP of the server manager |
FSM_FACTORIO_IP |
factorio_ip |
--game-bind-address |
0.0.0.0 |
Default IP for the factorio game server |
FSM_SERVER_PORT |
server_port |
--port |
80 |
Port of the server manager |
FSM_FACTORIO_PORT |
factorio_port |
--game-port |
34197 |
Default Port for the factorio game server |
FSM_FACTORIO_CONFIG_FILE |
config_file |
--config |
config/config.ini |
Specify location of Factorio config.ini file (relative to factorio root) |
FSM_BINARY |
factorio_binary |
--bin |
bin/x64/factorio |
Location of Factorio Server binary file (relative to factorio root). |
FSM_RCON_PORT |
rcon_port |
--rcon-port |
0 |
Specify port for rcon admin console. |
FSM_AUTOSTART |
autostart |
--autostart |
false |
Autostart factorio server on bootup of FSM. |
FSM_MODPACK_DIR |
mod_pack_dir |
--mod-pack-dir |
./mod_packs |
Directory to store mod packs (relative to server manager). |
FSM_FACTORIO_SAVES_DIR |
saves_dir |
--factorio-saves-dir |
saves |
Directory where factorio saves logs (relative to factorio root). |
FSM_FACTORIO_BASEMOD_DIR |
basemod_dir |
--factorio-basemod-dir |
data/base |
Location of factorios base-mod (relative to factorio root). |
FSM_FACTORIO_MODS_DIR |
mods_dir |
--factorio-mods-dir |
mods |
Location of factorios mods directory (relative to factorio root). |
FSM_FACTORIO_CONFIG_DIR |
config_directory |
--factorio-config-dir |
config |
Location of factorios config directory (relative to factorio root). |
FSM_FACTORIO_LOGFILE |
logfile |
--factorio-logfile |
factorio-current.log |
Filename of the factorio logfile (relative to factorio root). |
rcon_pass |
random generated on startup | Password for the rcon connection. | ||
FSM_FACTORIO_CREDENTIALS_FILE |
factorio_credentials_file |
--factorio-credentials-file |
./factorio.auth |
File where the login for the mods portal is saved in (relative to server manager). |
FSM_FACTORIO_ADMIN_FILE |
factorio_admin_file |
--factorio-admin-file |
server-adminlist.json |
File where factorio saves the admins (relative to factorio config dir). |
FSM_MAX_UPLOAD_SIZE |
max_upload_size |
--max-upload-size |
20 |
Maximum filesize for uploaded files in MB. |
SQ_LITE_DATABASE_FILE |
sq_lite_database_file |
--sq-lite-database-file |
sqlite.db |
Sqlite database file |
FSM_FACTORIO_SETTINGS_FILE |
settings_file |
--factorio-settings-file |
server-settings.json |
Settings file of the factorio server (relative to factorio config dir). |
FSM_CONSOLE_CACHE_SIZE |
console_cache_size |
--console-cache-size |
25 |
the amount of cached lines, inside the factorio output cache. |
FSM_CONSOLE_LOG_FILE |
console_log_file |
console-log-file |
factorio-server-console.log |
File so save factorio console logs into (relative to factorio root). |
FSM_CHAT_LOG_FILE |
chat_log_file |
--chat-log-file |
Save factorio game chat in a separate file. | |
FSM_SECURE |
secure |
--secure |
true |
Enable ssl/tls (on by default) |
FSM_GLIBC_CUSTOM |
glibc_custom |
--glibc-custom |
false |
By default false, if custom glibc is required set this to true and add glibc-loc and glibc-lib-loc parameters. |
FSM_GLIBC_LOCATION |
glibc_location |
--glibc-loc |
/opt/glibc-2.18/lib/ld-2.18.so |
Location glibc ld.so file if needed (ex. /opt/glibc-2.18/lib/ld-2.18.so). |
FSM_GLIBC_LIB |
glibc_lib_loc |
--glibc-lib-loc |
/opt/glibc-2.18/lib |
Location of glibc lib folder (ex. /opt/glibc-2.18/lib). |