mirror of
https://github.com/retspen/webvirtcloud
synced 2026-04-05 21:15:25 +00:00
Additional changes
This commit is contained in:
parent
e44e01cad4
commit
40738d7920
17 changed files with 289 additions and 19 deletions
|
|
@ -7,6 +7,8 @@ from instances.models import Instance
|
|||
from vrtManager.instance import wvmInstance
|
||||
from webvirtcloud.settings import WS_PORT
|
||||
from webvirtcloud.settings import WS_PUBLIC_HOST
|
||||
from webvirtcloud.settings import WS_PUBLIC_PORT
|
||||
from webvirtcloud.settings import WS_PUBLIC_PATH
|
||||
from libvirt import libvirtError
|
||||
|
||||
|
||||
|
|
@ -40,8 +42,9 @@ def console(request):
|
|||
console_websocket_port = None
|
||||
console_passwd = None
|
||||
|
||||
ws_port = console_websocket_port if console_websocket_port else WS_PORT
|
||||
ws_port = console_websocket_port if console_websocket_port else WS_PUBLIC_PORT
|
||||
ws_host = WS_PUBLIC_HOST if WS_PUBLIC_HOST else request.get_host()
|
||||
ws_path = WS_PUBLIC_PATH if WS_PUBLIC_PATH else '/'
|
||||
|
||||
if ':' in ws_host:
|
||||
ws_host = re.sub(':[0-9]+', '', ws_host)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue