debug: without check uploader in server.py
Some checks failed
Deploy on push / deploy (push) Failing after 22s
Some checks failed
Deploy on push / deploy (push) Failing after 22s
This commit is contained in:
parent
98d7c522fb
commit
e4d83d35eb
22
server.py
22
server.py
|
@ -1,4 +1,3 @@
|
||||||
import subprocess
|
|
||||||
from granian.constants import Interfaces
|
from granian.constants import Interfaces
|
||||||
from granian.server import Granian
|
from granian.server import Granian
|
||||||
|
|
||||||
|
@ -13,15 +12,12 @@ def is_docker_container_running(name):
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
logger.info("started")
|
logger.info("started")
|
||||||
|
|
||||||
if is_docker_container_running('uploader'):
|
granian_instance = Granian(
|
||||||
granian_instance = Granian(
|
"main:app",
|
||||||
"main:app",
|
address="0.0.0.0", # noqa S104
|
||||||
address="0.0.0.0", # noqa S104
|
port=PORT,
|
||||||
port=PORT,
|
threads=4,
|
||||||
threads=4,
|
websockets=False,
|
||||||
websockets=False,
|
interface=Interfaces.ASGI,
|
||||||
interface=Interfaces.ASGI,
|
)
|
||||||
)
|
granian_instance.serve()
|
||||||
granian_instance.serve()
|
|
||||||
else:
|
|
||||||
logger.info("'uploader' is not running. But very needed !!! \(^.^'\)")
|
|
Loading…
Reference in New Issue
Block a user