Added HTTP control stuff
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2021-04-15 00:31:53 +02:00
parent fffa8b2fef
commit 2b3d994cc2
5 changed files with 97 additions and 11 deletions

View File

@@ -12,3 +12,6 @@ class Config:
PROGRAM_URL = os.environ["PROGRAM_URL"]
DRY_RUN = ('--dry-run' in sys.argv) or bool(os.environ.get("DRY_RUN", False))
DEBUG = ('--debug' in sys.argv) or bool(os.environ.get("DEBUG", False))
HTTP_ENABLE = ('--no-http' not in sys.argv) and \
bool(os.environ.get("HTTP_ENABLE", "").upper() not in ['NO', 'FALSE', '0'])
HTTP_PORT = int(os.environ.get("HTTP_PORT", 8080))