aboutsummaryrefslogtreecommitdiffstats
path: root/puppet/role.role.j2.yaml
diff options
context:
space:
mode:
authorSteven Hardy <shardy@redhat.com>2017-07-11 15:45:52 +0100
committerSteven Hardy <shardy@redhat.com>2017-08-11 15:06:34 +0100
commitd8e253182053d5e813cd2c067ee1da453813a2fc (patch)
tree9a148c84679815c672e2c70eb18a339028350a1c /puppet/role.role.j2.yaml
parent1aad286ca39b59d1193d53db9ec25751b5854d48 (diff)
Convert compute-role.yaml to role.role.j2.yaml
Add some special-casing for backwards compatibility, such that the Compute role can be rendered via j2 for support of composable networks. Change-Id: Ieee446583f77bb9423609d444c576788cf930121 Partially-Implements: blueprint composable-networks
Diffstat (limited to 'puppet/role.role.j2.yaml')
-rw-r--r--puppet/role.role.j2.yaml30
1 files changed, 27 insertions, 3 deletions
diff --git a/puppet/role.role.j2.yaml b/puppet/role.role.j2.yaml
index c494141..5453e65 100644
--- a/puppet/role.role.j2.yaml
+++ b/puppet/role.role.j2.yaml
@@ -131,6 +131,12 @@ parameters:
role-specific and is merged with the values given to the ServerMetadata
parameter.
type: json
+{%- if role.deprecated_param_metadata is defined %}
+ {{role.deprecated_param_metadata}}:
+ default: {}
+ description: DEPRECATED - use {{role.name}}ServerMetadata instead
+ type: json
+{%- endif %}
ServerMetadata:
default: {}
description: >
@@ -142,6 +148,12 @@ parameters:
type: json
description: Optional scheduler hints to pass to nova
default: {}
+{%- if role.deprecated_param_scheduler_hints is defined %}
+ {{role.deprecated_param_scheduler_hints}}:
+ type: json
+ description: DEPRECATED - use {{role.name}}SchedulerHints instead
+ default: {}
+{%- endif %}
NodeIndex:
type: number
default: 0
@@ -245,7 +257,6 @@ conditions:
- DeploymentSwiftDataMap
- {get_param: Hostname}
- ""
-
{%- if role.deprecated_param_image is defined %}
deprecated_param_image_set:
not:
@@ -301,9 +312,17 @@ resources:
metadata:
map_merge:
- {get_param: ServerMetadata}
+{%- if role.deprecated_param_metadata is defined %}
+ - {get_param: {{role.deprecated_param_metadata}}}
+{%- endif %}
- {get_param: {{role.name}}ServerMetadata}
- {get_param: ServiceMetadataSettings}
- scheduler_hints: {get_param: {{role.name}}SchedulerHints}
+ scheduler_hints:
+ map_merge:
+{%- if role.deprecated_param_scheduler_hints is defined %}
+ - {get_param: {{role.deprecated_param_scheduler_hints}}}
+{%- endif %}
+ - {get_param: {{role.name}}SchedulerHints}
deployment_swift_data:
if:
- deployment_swift_data_map_unset
@@ -343,7 +362,12 @@ resources:
type: OS::TripleO::{{role.name}}::Ports::{{network.name}}Port
properties:
ControlPlaneIP: {get_attr: [{{server_resource_name}}, networks, ctlplane, 0]}
- IPPool: {get_param: {{server_resource_name}}IPs}
+ IPPool:
+ map_merge:
+{%- if role.deprecated_param_ips is defined %}
+ - {get_param: {{role.deprecated_param_ips}}}
+{%- endif %}
+ - {get_param: {{role.name}}IPs}
NodeIndex: {get_param: NodeIndex}
{%- endfor %}