Merge "Send config parameters in cluster update"
This commit is contained in:
commit
aeb56bd25c
@ -273,6 +273,9 @@ class TestClusterUpdate(TestCluster):
|
||||
"nk1": "nv1",
|
||||
"nk2": "nv2",
|
||||
},
|
||||
"config": {
|
||||
"cluster.stop_node_before_delete": "true",
|
||||
},
|
||||
"name": 'new_cluster',
|
||||
"profile_id": 'new_profile',
|
||||
"profile_only": False,
|
||||
@ -314,6 +317,7 @@ class TestClusterUpdate(TestCluster):
|
||||
|
||||
def test_cluster_update_defaults(self):
|
||||
arglist = ['--name', 'new_cluster', '--metadata', 'nk1=nv1;nk2=nv2',
|
||||
'--config', 'cluster.stop_node_before_delete=true',
|
||||
'--profile', 'new_profile', '--timeout', '30', '45edadcb']
|
||||
parsed_args = self.check_parser(self.cmd, arglist, [])
|
||||
self.cmd.take_action(parsed_args)
|
||||
|
@ -243,9 +243,11 @@ class UpdateCluster(command.ShowOne):
|
||||
parser.add_argument(
|
||||
'--config',
|
||||
metavar='<"key1=value1;key2=value2...">',
|
||||
help=_('s of the cluster. Default to {}. '
|
||||
help=_('Configuration of the cluster. '
|
||||
'This can be specified multiple times, or once with '
|
||||
'key-value pairs separated by a semicolon.'),
|
||||
'key-value pairs separated by a semicolon. '
|
||||
'Any existing configuration values on the cluster are '
|
||||
'wiped out when using this option.'),
|
||||
action='append'
|
||||
)
|
||||
parser.add_argument(
|
||||
@ -303,6 +305,7 @@ class UpdateCluster(command.ShowOne):
|
||||
strict=True,
|
||||
),
|
||||
'metadata': senlin_utils.format_parameters(parsed_args.metadata),
|
||||
'config': senlin_utils.format_parameters(parsed_args.config),
|
||||
'timeout': parsed_args.timeout,
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user