Added my server, updated Accus server
This commit is contained in:
parent
6058f8050f
commit
ff6e701296
@ -4,7 +4,9 @@ import datetime
|
|||||||
import time
|
import time
|
||||||
import traceback
|
import traceback
|
||||||
|
|
||||||
SERVERS = [{"ip": "136.143.41.50", "port": 19711, "last":datetime.datetime.now()}, {"ip": "73.181.147.35", "port": 19711, "last": datetime.datetime.now()}]
|
SERVERS = [{"ip": "136.143.97.184", "port": 19711, "last":datetime.datetime.now()},
|
||||||
|
{"ip": "73.181.147.35", "port": 19711, "last": datetime.datetime.now()},
|
||||||
|
{"ip": "g.hipstercat.fr", "port": 19711, "last": datetime.datetime.now()}]
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
listen_ip = "0.0.0.0"
|
listen_ip = "0.0.0.0"
|
||||||
@ -38,9 +40,10 @@ def queryloop(querysock):
|
|||||||
print("A new client has come")
|
print("A new client has come")
|
||||||
b = b''
|
b = b''
|
||||||
for i in range(len(SERVERS)):
|
for i in range(len(SERVERS)):
|
||||||
|
ip = SERVERS[i]["ip"]
|
||||||
b += "{:02d}".format(i).encode("ascii")
|
b += "{:02d}".format(i).encode("ascii")
|
||||||
b += b'\xac'
|
b += b'\xac'
|
||||||
b += SERVERS[i]["ip"].encode("ascii")
|
b += ip.encode("ascii")
|
||||||
b += b'\xac'
|
b += b'\xac'
|
||||||
b += str(SERVERS[i]["port"]).encode("ascii")
|
b += str(SERVERS[i]["port"]).encode("ascii")
|
||||||
b += b'\x00'
|
b += b'\x00'
|
||||||
@ -76,7 +79,7 @@ def cleanloop():
|
|||||||
now = datetime.datetime.now()
|
now = datetime.datetime.now()
|
||||||
for server in SERVERS:
|
for server in SERVERS:
|
||||||
if now > server["last"] + datetime.timedelta(minutes=2):
|
if now > server["last"] + datetime.timedelta(minutes=2):
|
||||||
if server["ip"] == "136.143.41.50" or server["ip"] == "73.181.147.35":
|
if server["ip"] == "136.143.97.184" or server["ip"] == "73.181.147.35" or server["ip"] == "g.hipstercat.fr":
|
||||||
# do not remove usual dedicated servers
|
# do not remove usual dedicated servers
|
||||||
continue
|
continue
|
||||||
print("Deleting %s:%s" % (server["ip"], server["port"]))
|
print("Deleting %s:%s" % (server["ip"], server["port"]))
|
||||||
|
Loading…
Reference in New Issue
Block a user