The 'record' option of the WebSocketProxy should be string
If proxy service (VNC, spice, serial) is started with the 'record' option, an exception is thrown. This is because WebSocketProxy expects a file path for the record argument instead of boolean value. This patch fixes this by changing 'record' to be string option. An empty string means no recording. Closes-Bug: #1559026 Change-Id: Id6cf7c65191bdaa579f7cdadea43230897436de6
This commit is contained in:
parent
caa8305030
commit
c5311439d6
@ -16,9 +16,11 @@
|
|||||||
from oslo_config import cfg
|
from oslo_config import cfg
|
||||||
|
|
||||||
opts = [
|
opts = [
|
||||||
cfg.BoolOpt('record',
|
cfg.StrOpt('record',
|
||||||
default=False,
|
help='This is the filename that will be used for storing '
|
||||||
help='Record sessions to FILE.[session_number]'),
|
'websocket frames received and sent by a proxy service '
|
||||||
|
'(like VNC, spice, serial) running on this host. If this '
|
||||||
|
'is not set (default), no recording will be done.'),
|
||||||
cfg.BoolOpt('daemon',
|
cfg.BoolOpt('daemon',
|
||||||
default=False,
|
default=False,
|
||||||
help='Become a daemon (background process)'),
|
help='Become a daemon (background process)'),
|
||||||
|
@ -61,7 +61,7 @@ class BaseProxyTestCase(test.NoDBTestCase):
|
|||||||
mock_init.assert_called_once_with(
|
mock_init.assert_called_once_with(
|
||||||
listen_host='0.0.0.0', listen_port='6080', source_is_ipv6=False,
|
listen_host='0.0.0.0', listen_port='6080', source_is_ipv6=False,
|
||||||
verbose=False, cert='self.pem', key=None, ssl_only=False,
|
verbose=False, cert='self.pem', key=None, ssl_only=False,
|
||||||
daemon=False, record=False, traffic=False,
|
daemon=False, record=None, traffic=False,
|
||||||
web='/usr/share/spice-html5', file_only=True,
|
web='/usr/share/spice-html5', file_only=True,
|
||||||
RequestHandlerClass=websocketproxy.NovaProxyRequestHandler)
|
RequestHandlerClass=websocketproxy.NovaProxyRequestHandler)
|
||||||
mock_start.assert_called_once_with()
|
mock_start.assert_called_once_with()
|
||||||
|
6
releasenotes/notes/bug-1559026-47c3fa3468d66b07.yaml
Normal file
6
releasenotes/notes/bug-1559026-47c3fa3468d66b07.yaml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
upgrade:
|
||||||
|
- The ``record`` configuration option for the console proxy
|
||||||
|
services (like VNC, serial, spice) is changed from
|
||||||
|
boolean to string. It specifies the filename that will
|
||||||
|
be used for recording websocket frames.
|
Loading…
x
Reference in New Issue
Block a user