Commit d62ed502 authored by Stephen Shirley's avatar Stephen Shirley
Browse files

Treat empty oob_program param as default



There is currently no way to reset oob_program back to its default from
the cmdline, which causes problems for cluster-merge. This patch means
that the following now works:
  gnt-cluster modify --node-parameters oob_program=
Signed-off-by: default avatarStephen Shirley <diamond@google.com>
Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
parent 377972f4
......@@ -2801,6 +2801,12 @@ class LUClusterSetParams(LogicalUnit):
utils.ForceDictType(self.op.ndparams, constants.NDS_PARAMETER_TYPES)
self.new_ndparams = cluster.SimpleFillND(self.op.ndparams)
# TODO: we need a more general way to handle resetting
# cluster-level parameters to default values
if self.new_ndparams["oob_program"] == "":
self.new_ndparams["oob_program"] = \
constants.NDC_DEFAULTS[constants.ND_OOB_PROGRAM]
if self.op.nicparams:
utils.ForceDictType(self.op.nicparams, constants.NICS_PARAMETER_TYPES)
self.new_nicparams = cluster.SimpleFillNIC(self.op.nicparams)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment