factorio-server-manager/README.md

113 lines
4.1 KiB
Markdown
Raw Normal View History

2016-05-08 15:30:18 +02:00
[![Build Status](https://travis-ci.org/MajorMJR/factorio-server-manager.svg?branch=master)](https://travis-ci.org/MajorMJR/factorio-server-manager)
2016-04-20 04:00:40 +02:00
#Factorio Server Manager
2016-04-27 17:30:25 +02:00
###A tool for managing Factorio servers.
This tool runs on a Factorio server and allows management of the Factorio server, saves, mods and many other features.
## Features
* Allows control of the Factorio Server, starting and stopping the Factorio binary.
* Allows the management of save files, upload, download and delete saves.
* Manage installed mods, upload new ones, delete uneeded mods. Enable or disable individual mods.
* Allow viewing of the server logs and current configuration.
2016-05-01 03:14:59 +02:00
* Authentication for protecting against unauthorized users
* Available as a Docker container
2016-04-27 17:30:25 +02:00
## Installation
2016-04-25 06:32:06 +02:00
1. Download the latest release
* [https://github.com/MajorMJR/factorio-server-manager/releases](https://github.com/MajorMJR/factorio-server-manager/releases)
2016-04-27 17:30:25 +02:00
2. Download the Factorio Standalone server and install to a known directory.
3. Run the server binary file, use the --dir flag to point the management server to your Factorio installation.
2016-04-27 19:38:19 +02:00
* ```./factorio-server-manager --dir /home/user/.factorio ```
2016-04-27 17:30:25 +02:00
4. Visit [localhost:8080](localhost:8080) in your web browser.
2016-04-20 04:00:40 +02:00
## Usage
2016-05-01 03:15:24 +02:00
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
2016-09-27 17:04:00 +02:00
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
2016-09-27 17:04:00 +02:00
Specify location of Factorio config.ini file (default "config/config.ini")
-dir string
2016-09-27 17:04:00 +02:00
Specify location of Factorio directory. (default "./")
-host string
2016-09-27 17:04:00 +02:00
Specify IP for webserver to listen on. (default "0.0.0.0")
-max-upload int
2016-09-27 17:04:00 +02:00
Maximum filesize for uploaded files (default 20MB). (default 20971520)
-port string
2016-09-27 17:04:00 +02:00
Specify a port for the server. (default "8080")
2016-04-20 05:16:36 +02:00
Example:
2016-04-20 05:16:36 +02:00
./factorio-server-manager --dir /home/user/.factorio --host 10.0.0.1
2016-04-20 05:16:36 +02:00
```
2016-04-28 02:19:07 +02:00
## Manage Factorio Server
2016-05-15 16:17:46 +02:00
![Factorio Server Manager Screenshot](http://i.imgur.com/q7tbzdH.png "Factorio Server Manager")
2016-04-28 02:19:07 +02:00
## Manage save files
2016-05-15 16:17:46 +02:00
![Factorio Server Manager Screenshot](http://i.imgur.com/M7kBAhI.png "Factorio Server Manager")
2016-04-28 02:19:07 +02:00
## Manage mods
2016-05-15 16:17:46 +02:00
![Factorio Server Manager Screenshot](http://i.imgur.com/L62Yb2W.png "Factorio Server Manager")
2016-04-28 02:19:07 +02:00
## Development
The backend is built as a REST API via the Go web application.
It also acts as the webserver to serve the front end react application
All api actions are accessible with the /api route. The frontend is accessible from /.
2016-04-20 05:16:36 +02:00
2016-04-27 17:30:25 +02:00
#### Requirements
2016-04-20 05:16:36 +02:00
+ Go 1.6
+ NodeJS 4.2.6
#### Building the Go backend
Go Application which manages the Factorio server.
API requests for managing the Factorio server are sent to /api.
The frontend code is served by a HTTP file server running on /.
```
2016-04-20 05:16:36 +02:00
git clone https://github.com/MajorMJR/factorio-server-manager.git
cd factorio-server-manager
go build
```
#### Building the React frontend
Frontend is built using React and the AdminLTE CSS framework. See app/dist/ for AdminLTE included files and license.
The root of the UI application is served at app/index.html. Run the npm build script and the Go application during development to get live rebuilding of the UI code.
All necessary CSS and Javascript files are included for running the UI.
Transpiled bundle.js application is output to app/bundle.js, 'npm run build' script starts webpack to build the React application for development
```
install nodejs (use nvm)
cd ui/
npm install
npm run build
Start factorio-server-manager binary in another terminal
```
## Contributing
1. Fork it!
2. Create your feature branch: `git checkout -b my-new-feature`
3. Commit your changes: `git commit -am 'Add some feature'`
4. Push to the branch: `git push origin my-new-feature`
5. Submit a pull request :D
2016-04-20 05:16:36 +02:00
## Authors
* **Mitch Roote** - [roote.me](https://roote.me)
## License
This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details