factoriotools / factorio-docker

Factorio headless server in a Docker container
https://hub.docker.com/r/factoriotools/factorio/
MIT License
1.06k stars 237 forks source link

Merge in games-on-k8s/docker-factorio gen_config #299

Closed deefdragon closed 3 years ago

deefdragon commented 4 years ago

games-on-k8s/docker-factorio has been effectively abandoned, but has gen_config.py, which is very powerful for the creation of the server-settings.json file. Addition of gen_config would allow for one line server launches (as opposed to starting, stoping, editing the config, and restarting), much easier kubernetes integration, and much easier public hosting of games.

License is also MIT.

I would be willing to do the merge, testing, and PR if the addition of gen_config.py is acceptable.

SuperSandro2000 commented 4 years ago

I don't really want to add python just for generating the config.

deefdragon commented 4 years ago

Just checked, and you do have busybox sed in the container. I would be willing to write a bash script that took a template and replaced all the values with either defaults, or the environment parameters. Only additions then would be the template and new script.

It would not take much to actually expand the script to any other configs that the user may want to edit.

SuperSandro2000 commented 4 years ago

We can also add the standalone sed cause compared to full blown python it is tiny. I would merge it if it is error proof (eg missing variables) and maintainable.

deefdragon commented 4 years ago

Moved to PR #304

jonfairbanks commented 4 years ago

This would be an awesome addition, thanks for taking this on.