Heat templates for deploying OpenStack
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

55 lines
2.1 KiB

heat_template_version: wallaby
description: Create networks to split out Overcloud traffic
parameters:
CtlplaneNetworkCidrs:
type: json
description: Cidrs for the ctlplane network.
CtlplaneNetworkAttributes:
type: json
default: {}
description: >
A map containing attributes of the undercloud ctlplane network and
subnets. NOTE: The value for this parameter is automatically populated in
the plan environment by tripleoclient.
resources:
{%- for network in networks if network.enabled|default(true) %}
{%- set network_name = network.compat_name|default(network.name) %}
{{network_name}}Network:
type: OS::TripleO::Network::{{network.name}}
{%- endfor %}
NetworkExtraConfig:
type: OS::TripleO::Network::ExtraConfig
outputs:
net_cidr_map:
value:
# NOTE(hjensas): If a network does not have any network_cidrs, fall back
# to the ctlplane (provisioning) network.
{%- for network in networks if network.enabled|default(true) %}
{%- set network_name = network.compat_name|default(network.name) %}
{{network.name_lower}}:
yaql:
data:
network_cidrs: {get_attr: [{{network_name}}Network, network_cidrs]}
ctlplane_cidrs: {get_param: CtlplaneNetworkCidrs}
expression: switch(not isList($.data.network_cidrs) => $.data.ctlplane_cidrs, $.data.network_cidrs => $.data.network_cidrs)
{%- endfor %}
net_ip_version_map:
value:
{%- for network in networks if network.enabled|default(true) %}
{%- set network_name = network.compat_name|default(network.name) %}
{{network.name_lower}}: {get_attr: [{{network_name}}Network, ip_version]}
{%- endfor %}
net_attributes_map:
value:
ctlplane: {get_param: CtlplaneNetworkAttributes}
{%- for network in networks if network.enabled|default(true) %}
{%- set network_name = network.compat_name|default(network.name) %}
{{network.name_lower}}:
network: {get_attr: [{{network_name}}Network, network_attrs]}
subnets: {get_attr: [{{network_name}}Network, subnet_attrs]}
{%- endfor %}