diff --git a/README.md b/README.md index c167b53..c81349f 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -Minetest server list +Luanti server list ==================== Setting up the webpage @@ -32,7 +32,7 @@ Embedding the server list in a page ... + Setting up the server @@ -75,7 +75,7 @@ Setting up the server $ ./server.py $ # Or for production: - $ uwsgi -s /tmp/minetest-master.sock --plugin python -w server:app --enable-threads + $ uwsgi -s /run/serverlist.sock --plugin python -w server:app --enable-threads $ # Then configure according to http://flask.pocoo.org/docs/deploying/uwsgi/ 7. (optional) Configure the proxy server, if any. You should make the server @@ -83,10 +83,12 @@ Setting up the server should be served from `list.json`. Example for nginx: root /path/to/server/static; - rewrite ^/list$ /list.json; + rewrite ^/$ /index.html break; + rewrite ^/list$ /list.json break; try_files $uri @uwsgi; location @uwsgi { - uwsgi_pass ...; + include uwsgi_params; + uwsgi_pass unix:/run/serverlist.sock; } Setting up the server (Apache version) @@ -96,30 +98,29 @@ If you wish to use Apache to host the server list, do steps 1-2, 4, above. Addit # This config assumes you have the server list at DocumentRoot. # Visitors to the server list in this config would visit http://local.server/ and - # apache would serve up the output from server.py. Static resources would be served - # from http://local.server/static. + # apache would serve up the output from server.py. - # Where are the minetest-server files located? - DocumentRoot /var/games/minetest/serverlist + # Where are the serverlist files located? + DocumentRoot /var/games/luanti/serverlist # Serve up server.py at the root of the URL. - WSGIScriptAlias / /var/games/minetest/serverlist/server.py + WSGIScriptAlias / /var/games/luanti/serverlist/server.py # The name of the function that we call when we invoke server.py WSGICallableObject app # These options are necessary to enable Daemon mode. Without this, you'll have strange behavior # with servers dropping off your list! You can tweak threads as needed. See mod_wsgi documentation. - WSGIProcessGroup minetest-serverlist - WSGIDaemonProcess minetest-serverlist threads=2 + WSGIProcessGroup luanti-serverlist + WSGIDaemonProcess luanti-serverlist threads=2 - + Require all granted License ------- -The Minetest server list code is licensed under the GNU Lesser General Public +The Luanti server list code is licensed under the GNU Lesser General Public License version 2.1 or later (LGPLv2.1+). A LICENSE.txt file should have been supplied with your copy of this software containing a copy of the license. diff --git a/config-example.py b/config-example.py index 4aca5bf..c5a243e 100644 --- a/config-example.py +++ b/config-example.py @@ -8,7 +8,7 @@ PORT = 5000 # Amount of time, is seconds, after which servers are removed from the list -# if they haven't updated their listings. Note: By default Minetest servers +# if they haven't updated their listings. Note: By default Luanti servers # only announce once every 5 minutes, so this should be more than 300. PURGE_TIME = 350 diff --git a/server.py b/server.py index f5d262f..66d903c 100755 --- a/server.py +++ b/server.py @@ -281,7 +281,7 @@ def checkRequestAddress(server): return ADDR_IS_INVALID # if not ipv6, there must be at least one dot (two components) # Note: This is not actually true ('com' is valid domain), but we'll assume - # nobody who owns a TLD will ever host a Minetest server on the root domain. + # nobody who owns a TLD will ever host a Luanti server on the root domain. # getaddrinfo also allows specifying IPs as integers, we don't want people # to do that either. if ":" not in name and "." not in name: @@ -302,7 +302,7 @@ def checkRequestAddress(server): return ADDR_IS_INVALID_PORT # unicode in hostname - # Not sure about Python but the Minetest client definitely doesn't support it. + # Not sure about Python but the Luanti client definitely doesn't support it. if any(ord(c) > 127 for c in name): return ADDR_IS_UNICODE @@ -358,7 +358,7 @@ def checkRequestSchema(server): server[name] = server[name].lower() in ("true", "1") continue # Accept strings in integer fields but convert it to an - # integer, for interoperability with e.g. minetest.write_json. + # integer, for interoperability with e.g. core.write_json(). if data[1] == "int": server[name] = int(server[name]) continue diff --git a/static/index.html b/static/index.html index 26915d5..b478daa 100644 --- a/static/index.html +++ b/static/index.html @@ -2,7 +2,7 @@ - Minetest server list + Luanti server list