mirror of
https://github.com/GNS3/gns3-server.git
synced 2025-06-21 00:22:56 +00:00
WebSocket binary mode support for docker
This commit is contained in:
@ -500,9 +500,11 @@ class DockerVM(BaseNode):
|
||||
|
||||
while True:
|
||||
msg = yield from ws.receive()
|
||||
if msg.tp == aiohttp.MsgType.text:
|
||||
if msg.tp == aiohttp.MsgType.TEXT:
|
||||
out.feed_data(msg.data.encode())
|
||||
elif msg.tp == aiohttp.MsgType.error:
|
||||
if msg.tp == aiohttp.MsgType.BINARY:
|
||||
out.feed_data(msg.data)
|
||||
elif msg.tp == aiohttp.MsgType.ERROR:
|
||||
log.critical("Docker WebSocket Error: {}".format(msg.data))
|
||||
else:
|
||||
out.feed_eof()
|
||||
|
Reference in New Issue
Block a user