OpenFactorioServerManager / factorio-server-manager

A tool to help manage Factorio multiplayer servers including mods and save games.
MIT License
556 stars 131 forks source link

0.5.2 - No Content on UI #62

Closed OnkelDom closed 6 years ago

OnkelDom commented 7 years ago

I have updated the fsm to 0.5.2 and there are no content on the webinterface.

Log: factorio@dlh-srv01:~/srv02$ ./factorio-server-manager -conf "config/fsm.conf" 2016/11/03 14:35:45 Error in reading config/server-settings.json: json: cannot unmarshal object into Go value of type string 2016/11/03 14:35:45 Loaded Factorio settings from config/server-settings.json, settings: &{Name:OnkelDom - #2 Description:Dedicated Factorio Server #2 Tags:[] MaxPlayers:10 Visibility: Username:######## Password:######## Token:######## GamePassword:krassey RequireUserVerification:true MaxUploadInKilobytesPerSecond:0 IgnorePlayerLimitForReturningPlayers:false AllowCommands:admins-only AutosaveInterval:30 AutosaveSlots:3 AfkAutoKickInterval:0 AutoPause:true OnlyAdminsCanPauseThegame:true Admins:[OnkelDom ThommyFFM] AutosaveOnlyOnServer:true} 2016/11/03 14:35:45 Created user: ######## Starting server on: 0.0.0.0:34201

Config: { "factorio_dir": "/home/factorio/srv02/", "factorio_binary": "bin/x64/factorio", "config_directory": "config", "saves_dir": "saves", "mods_dir": "mods", "settings_file": "server-settings.json", "config_file": "config.ini", "username": "########", "password": "########", "database_file": "auth.leveldb", "cookie_encryption_key": "########", "server_port": "34201" }

Server-Settings: { "name": "OnkelDom - #2", "description": "Dedicated Factorio Server #2", "tags": [""], "maxplayers": 10, **"visibility": { "public": true, "lan": true },_** "username": "########", "password": "########", "token": "########", "game_password": "krassey", "require_user_verification": true, "max_upload_in_kilobytes_per_second": 0, "ignore_player_limit_for_returning_players": false, "allow_commands": "admins-only", "autosave_interval": 30, "autosave_slots": 3, "afk_autokick_interval": 0, "auto_pause": true, "only_admins_can_pause_the_game": true, "autosave_only_on_server": true, "admins": ["########","########"] }

In the startup log in front of this post can you see that the visibility are not loaded. Is that the problem and is there a way to fix it? On the webinterface there load no content. the site is white.

mroote commented 7 years ago

Can you try the latest release again and see if it is fixed? I uploaded a patched version last night that should fix this issue. The current release works on my machine atleast and the UI loads correctly.

OnkelDom commented 7 years ago

The GUI works fine. In the game settings section are not all fields optimized die there content. Admins are an password field etc.

When i start a server over the gui there is an error with the server-settings.json 2.511 Error Util.cpp:57: Error while reading file /home/factorio/srv02/server-settings.json: /home/factorio/srv02/server-settings.json: cannot open file There is ignoring the config folder. My server-settings.json in the subfolder "config". See the first post.

OnkelDom commented 7 years ago

i post you from my home more problems with the game configuration site later

OnkelDom commented 7 years ago

Sorry That are start from the gui: 0.062 Program arguments: "bin/x64/factorio" "--start-server" "saves/newworld.zip" "--port" "34198" "--server-settings" "/home/factorio/srv02/server-settings.json"

mroote commented 7 years ago

Yeah configuring the server-settings.json is still a bit of a WIP. Some of the types for the different setting fields are getting switched around causing issues.

I'm still working on improving the server-settings UI, of course any PR's are welcome :)

OnkelDom commented 7 years ago

The server-settings frame a to big. you can see it an the buttom. there is a scrolbar. The Admins and Tags can you make as text with , seperator or json string. The Visibility can you create with public true/false, lan true/false select buttons. fsm-server-settings

OnkelDom commented 7 years ago

The config.ini show doesnt work: on my server its in config/config.ini 2016-11-03 22_06_58-factorio server manager

OnkelDom commented 7 years ago

can you make a variable in the fsm.conf for the factorio server port? i have multiple servers an there select only the default port at a restart of fsm on the main site "server control -> advanced"

can you implement a funktion that i can load automatic the last map? the variable for the server start is "--start-server-load-latest" with a option on the server control site?

mroote commented 7 years ago

Ok lots of issues here :)

I replicated the first case, if you don't specify the --dir flag when starting factorio-server-manager then the paths to saves, mods, config etc. don't get replaced with the full path. For now you should be able just to specify the location of the Factorio directory with the dir flag. I'll have to rework how the server manager starts up to load the config file properly.

Your fsm.conf file has a few unneeded settings here's one that should work: { "username": "admin", "password": "factorio", "database_file": "auth.leveldb", "cookie_encryption_key": "topsecretkey", "server_port": "34201", "settings_file": "server-settings.json", }

That UI bug with the scrollbar is something messed up with the Bootstrap formatting. Could you open another issue for that one? I'm sure someone will be able to spot where the error is.

Adding an option for loading the latest save file should be straightforward. Could you open another issue for that one too?