Make ciclic read config.py to retrieve PORT

This commit is contained in:
tituspijean 2022-01-16 19:46:02 +01:00
parent de28fea3b5
commit 30d5d8d98e
No known key found for this signature in database
GPG key ID: EF3B0D7CC0A94720

6
ciclic
View file

@ -7,8 +7,12 @@ import requests
from argh.decorators import named
try:
from config import *
except ImportError:
PORT="4242"
DOMAIN = "localhost:4242"
DOMAIN = "localhost:" + str(PORT)
def require_token():
if os.path.exists("token") and open("token").read().strip():