node extract provisioned - use network_config_update

In change If53577a26edcb2dc67458603286471dfb87f0bda
network_deployment_actions was replaced with
network_config_update in the baremetal YAML definition.

Update the overcloud node extract provisioned command
to set network_config_update instead of the removed
network_deployment_actions parameter.

Related-Bug: #1951458
Change-Id: I3d52e17400d4c7b7a7ac8878eb289e8a84df5459
This commit is contained in:
Harald Jensås 2021-11-18 19:47:40 +01:00
parent 98e692d00f
commit 9ad9323b0a
2 changed files with 6 additions and 7 deletions

View File

@ -908,7 +908,7 @@ class TestExtractProvisionedNode(test_utils.TestCommand):
'count': 1,
'hostname_format': '%stackname%-novacompute-%index%',
'defaults': {
'network_config': {'network_deployment_actions': ['CREATE'],
'network_config': {'network_config_update': False,
'physical_bridge_name': 'br-ex',
'public_interface_name': 'nic1',
'template': 'templates/compute.j2'},
@ -928,7 +928,7 @@ class TestExtractProvisionedNode(test_utils.TestCommand):
'hostname_format': '%stackname%-controller-%index%',
'defaults': {
'network_config': {'default_route_network': ['External'],
'network_deployment_actions': ['CREATE'],
'network_config_update': False,
'networks_skip_config': ['Tenant'],
'physical_bridge_name': 'br-ex',
'public_interface_name': 'nic1',

View File

@ -582,15 +582,14 @@ class ExtractProvisionedNode(command.Command):
role_name + 'NetworkConfigTemplate')
if parameters.get(role_name + 'NetworkDeploymentActions'):
net_conf['network_deployment_actions'] = parameters.get(
network_deployment_actions = parameters.get(
role_name + 'NetworkDeploymentActions')
else:
net_conf['network_deployment_actions'] = parameters.get(
network_deployment_actions = parameters.get(
'NetworkDeploymentActions', ['CREATE'])
if isinstance(net_conf['network_deployment_actions'], str):
net_conf['network_deployment_actions'] = net_conf[
'network_deployment_actions'].split(',')
net_conf['network_config_update'] = (
'UPDATE' in network_deployment_actions)
# The NetConfigDataLookup parameter is of type: json, but when
# not set it returns as string '{}'