Merge "Enable Neutron LBaaS Integration"
[apex-tripleo-heat-templates.git] / network / networks.j2.yaml
index ef977d8..5aec597 100644 (file)
@@ -1,4 +1,4 @@
-heat_template_version: ocata
+heat_template_version: pike
 
 description: Create networks to split out Overcloud traffic
 
@@ -15,3 +15,23 @@ resources:
 
   NetworkExtraConfig:
     type: OS::TripleO::Network::ExtraConfig
+
+
+outputs:
+  net_cidr_map:
+    value:
+      # NOTE(gfidente): we need to replace the null value with a
+      # string to work around https://bugs.launchpad.net/heat/+bug/1700025
+      {%- for network in networks %}
+        {%- if network.name != 'InternalApi' %}
+      {{network.name_lower}}:
+        yaql:
+          data: {get_attr: [{{network.name}}Network, subnet_cidr]}
+          expression: str($.data).replace('null', 'disabled')
+        {%- else  %}
+      {{network.name_lower}}:
+        yaql:
+          data: {get_attr: [InternalNetwork, subnet_cidr]}
+          expression: str($.data).replace('null', 'disabled')
+        {%- endif %}
+      {%- endfor %}