WebHost: split autolaunch and autogen services

This commit is contained in:
Fabian Dill
2021-12-13 05:48:33 +01:00
parent 3bf367d630
commit 3f20bdaaa2
3 changed files with 29 additions and 11 deletions

View File

@@ -14,7 +14,7 @@ from WebHostLib import app as raw_app
from waitress import serve
from WebHostLib.models import db
from WebHostLib.autolauncher import autohost
from WebHostLib.autolauncher import autohost, autogen
from WebHostLib.lttpsprites import update_sprites_lttp
from WebHostLib.options import create as create_options_files
@@ -45,6 +45,8 @@ if __name__ == "__main__":
create_options_files()
if app.config["SELFLAUNCH"]:
autohost(app.config)
if app.config["SELFGEN"]:
autogen(app.config)
if app.config["SELFHOST"]: # using WSGI, you just want to run get_app()
if app.config["DEBUG"]:
autohost(app.config)