Skip to content

Commit

Permalink
Add empty list as default for adoption scenarios without networker nodes
Browse files Browse the repository at this point in the history
Networker nodes are not required in all adoption topologies.
We need to provide default filter to be able to generate adoption_vars
template if osp-networkers are not defined in _vm_groups.

Fixes: #2548
  • Loading branch information
ciecierski committed Dec 3, 2024
1 parent be20061 commit 5d0ba82
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion roles/adoption_osp_deploy/templates/adoption_vars.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ edpm_computes: |
["{{ compute }}.{{ cifmw_adoption_osp_deploy_scenario.cloud_domain }}"]="{{ node_nets.networks.ctlplane.ip_v4 }}"
{% endfor %}
edpm_networkers: |
{% for networker in _vm_groups['osp-networkers'] %}
{% for networker in _vm_groups['osp-networkers'] | default([]) %}
{% set node_nets = cifmw_networking_env_definition.instances[networker] %}
["{{ networker }}.{{ cifmw_adoption_osp_deploy_scenario.cloud_domain }}"]="{{ node_nets.networks.ctlplane.ip_v4 }}"
{% endfor %}
Expand Down

0 comments on commit 5d0ba82

Please sign in to comment.