none 9 months ago
parent 7b344a41eb
commit 1bc483a3b6

@ -37,8 +37,6 @@ rp_serv.start()
#http сервер #http сервер
http = Thread(target = server_http) http = Thread(target = server_http)
http.start() http.start()
sleep(1)
os.chdir("../") # возвращаемся в корень
# сервер для пинга # сервер для пинга
server = Thread(target = server, args=(http_port,)) server = Thread(target = server, args=(http_port,))
server.start() server.start()

@ -38,8 +38,7 @@ def port_gen():
def server_http(): def server_http():
while True: while True:
try: try:
os.chdir("cached") os.system("python -m http.server --directory cached")
os.system("python -m http.server")
except Exception as e: except Exception as e:
print("SERVER_HTTP FALLED") print("SERVER_HTTP FALLED")
logging.critical(e, exc_info=True) logging.critical(e, exc_info=True)

Loading…
Cancel
Save