fixed an error in websockets and uploded vue

fixed an error in websockets and uploded vue
This commit is contained in:
ori agranat
2019-03-08 15:55:36 +02:00
parent e4278b9ef7
commit f6dc1e8094
5 changed files with 11923 additions and 3 deletions

View File

@@ -12,8 +12,9 @@ define("port", default=8888, help="run on the given port", type=int)
class ChameleonApplication(tornado.web.Application):
def __init__(self):
handlers = [(r"/", MainHandler),
(r"/(.*)", tornado.web.StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), "../../Site")}),
(r"/websocket", ChameleonWebSocket),
#always keep websocket up here and not under any handler
(r"/(.*)", tornado.web.StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), "../../Site")}),
(r"/CSS/(.*)", tornado.web.StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), "../../Site/CSS")}),
(r"/JS/(.*)", tornado.web.StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), "../../Site/JS")}),
(r"/assets/(.*)", tornado.web.StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), "../../Site/assets")})]