mirror of
https://github.com/krateng/maloja.git
synced 2023-08-10 21:12:55 +03:00
Switched to explicit server execution
This commit is contained in:
parent
a598ba96de
commit
04947cb97d
@ -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'
|
||||
|
@ -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,
|
||||
)
|
||||
|
@ -310,7 +310,3 @@ def run_server():
|
||||
except OSError:
|
||||
log("Error. Is another Maloja process already running?")
|
||||
raise
|
||||
|
||||
|
||||
|
||||
run_server()
|
||||
|
Loading…
Reference in New Issue
Block a user