nova-web/web/__main__.py

21 lines
521 B
Python
Raw Normal View History

2023-07-25 03:38:53 +02:00
try:
from cheroot.wsgi import Server as WSGIServer, PathInfoDispatcher
except ImportError:
from cherrypy.wsgiserver import CherryPyWSGIServer as WSGIServer, WSGIPathInfoDispatcher as PathInfoDispatcher
from app import production
d = PathInfoDispatcher({'/': production})
server = WSGIServer(('0.0.0.0', 2323), d)
print('Ready...')
try:
print('Starting...')
print()
print('* http://localhost:2323')
print('* https://nova-oss.com')
server.start()
except KeyboardInterrupt:
server.stop()