Switched to explicit server execution

This commit is contained in:
krateng 2022-03-27 22:03:46 +02:00
parent a598ba96de
commit 04947cb97d
3 changed files with 3 additions and 13 deletions

View File

@ -10,6 +10,7 @@ from .setup import setup
from . import tasks
from .. import __pkginfo__ as info
from .. import globalconf
from .. import server
def print_header_info():
@ -87,7 +88,7 @@ def onlysetup():
def direct():
print_header_info()
setup()
from .. import server
server.run_server()
def debug():
os.environ["MALOJA_DEV_MODE"] = 'true'

View File

@ -14,17 +14,10 @@ from .control import getInstance
setproctitle.setproctitle("maloja_supervisor")
def update():
log("Updating...",module="supervisor")
try:
os.system("pip3 install maloja --upgrade --no-cache-dir")
except:
log("Could not update.",module="supervisor")
def start():
try:
return subprocess.Popen(
["python3", "-m", "maloja.server"],
["python3", "-m", "maloja","run"],
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)

View File

@ -310,7 +310,3 @@ def run_server():
except OSError:
log("Error. Is another Maloja process already running?")
raise
run_server()