summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2020-12-16 17:43:27 -0300
committerJesusaves <cpntb1@ymail.com>2020-12-16 17:43:27 -0300
commitfdbbdcf40f300e38a08bb3b6a4bc809156cb52aa (patch)
treeb6287a50df2bd5c428364d3407feee93b03df839 /README.md
parenta41444dbd2078b36cfdb5e5dccc2f6b26676c079 (diff)
downloadserver-fdbbdcf40f300e38a08bb3b6a4bc809156cb52aa.tar.gz
server-fdbbdcf40f300e38a08bb3b6a4bc809156cb52aa.tar.bz2
server-fdbbdcf40f300e38a08bb3b6a4bc809156cb52aa.tar.xz
server-fdbbdcf40f300e38a08bb3b6a4bc809156cb52aa.zip
Add back the autotools from the old version
Diffstat (limited to 'README.md')
-rw-r--r--README.md84
1 files changed, 84 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..5edc381
--- /dev/null
+++ b/README.md
@@ -0,0 +1,84 @@
+# Installing
+
+Make sure you have the following dependencies:
+
+Python3 Modules:
+random, threading, time, hashlib, json, zlib, base64, mysql.connector, syslog
+Should also come with Python: SocketServer, BaseHTTPServer.
+
+You need Python 3.6, other versions were not tested and may not work at all.
+You'll also need a local instance of MySQL running. MariaDB should also work.
+
+mysql.connector can be installed with `pip3 install mysql-connector`.
+
+## Before all
+
+Create database `spheres`, and user `evol` with password `evol`, granting all rights
+to it. Or configure sql.py accordingly.
+
+Then, execute `main.sql` against the newly created SQL Database.
+It's installed now.
+
+### Alternative
+You can also run this command to prepare MySQL for you. You need to have mysql
+installed to run this command!
+
+```sh
+make initdb
+```
+
+## Other things you'll need
+
+You need a file called salt.txt, with 1~5 random alphanumeric characters.
+If you used `make initdb`, this file was created to you with a random 0~999 number.
+You probably should change it, but it is fine as long as it can't be guessed.
+
+If you plan in support SSL, you will need a pair of files: key.pem and certificate.pem
+`make initdb` will make these files for you; But if you don't want to support SSL,
+update the relevant setting on server.py file.
+
+Remember: Clients may attempt SSL connection if they can download certificate.pem!
+
+# Running the server
+Simply run server.py and vĂ³ila.
+
+Spheres Server will be running on port provided by pass.json
+Remember to configure server.py if you plan on running this outside localhost.
+
+# Securing the server
+
+You should, besides changing default sql user/password combination, use Fail2Ban.
+Fail2Ban will block harmful clients which could otherwise DoS your server.
+
+See also their official website: https://www.fail2ban.org
+
+# The client
+The client should work out-of-the-box, but a few concerns are to be made.
+
+1. Only localhost is accepted right now,
+2. You must serve several files under localhost:80, eg.
+ * version.txt
+ * units.json
+ * quests.json
+3. You must have Update Server running and properly configured,
+
+Remember to run the server along Fail2ban and other technologies.
+
+Client auto-updater is not provided, but is possible.
+
+# The Update Server
+
+The client will request images missing on it to the update server.
+Simply download it from the repository.
+
+Workflow is: First you use comp.py, and then, fixit.sh
+
+After that, the Update Server is ready to be enabled, and you can do so by running
+`./server.py` on the relevant folder.
+
+Update Server should already be running when this server is running.
+Failure to do so might lead to infinite hangs on clients as they await for a reply.
+Caution doesn't hurt.
+
+
+