From 4f75f76db88f4a8f17df27c77091af1114e49342 Mon Sep 17 00:00:00 2001 From: liuzheng712 Date: Thu, 25 Feb 2016 20:05:20 +0800 Subject: [PATCH] fix: web socket url update --- jumpserver/views.py | 2 +- run_websocket.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/jumpserver/views.py b/jumpserver/views.py index afe5ddd38..b95c314b4 100644 --- a/jumpserver/views.py +++ b/jumpserver/views.py @@ -356,7 +356,7 @@ def web_terminal(request): if asset: print asset hostname = asset.hostname - web_terminal_uri = '%s/terminal?id=%s&role=%s' % (WEB_SOCKET_HOST, asset_id, role_name) + web_terminal_uri = '%s/ws/terminal?id=%s&role=%s' % (WEB_SOCKET_HOST, asset_id, role_name) return render_to_response('jlog/web_terminal.html', locals()) diff --git a/run_websocket.py b/run_websocket.py index 2c761ee50..0f758b947 100755 --- a/run_websocket.py +++ b/run_websocket.py @@ -439,8 +439,8 @@ def main(): } tornado_app = tornado.web.Application( [ - # (r'/monitor', MonitorHandler), - (r'/terminal', WebTerminalHandler), + (r'/monitor', MonitorHandler), + (r'/ws/terminal', WebTerminalHandler), (r'/kill', WebTerminalKillHandler), (r'/exec', ExecHandler), (r"/static/(.*)", tornado.web.StaticFileHandler,