summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2017-07-18 02:45:49 +0000
committerGerrit Code Review <review@openstack.org>2017-07-18 02:45:49 +0000
commit96f6010004aef064fdb7b6d7c8eb2884b6795650 (patch)
treeb01e49931233fe2c223fb5b30a92571a36b004da
parenteeec8797591fe7268d24c9e6ff1c38750173f746 (diff)
parent68e582323e8d02638b31575f1c6aa40380cb1d0f (diff)
Merge "Handles {controller,NovaCompute}ExtraConfig deprecation in ovecloud.j2"
-rw-r--r--docker/docker-steps.j254
-rw-r--r--overcloud.j2.yaml32
-rw-r--r--puppet/puppet-steps.j253
3 files changed, 81 insertions, 58 deletions
diff --git a/docker/docker-steps.j2 b/docker/docker-steps.j2
index ab75b7eb..4b0c8789 100644
--- a/docker/docker-steps.j2
+++ b/docker/docker-steps.j2
@@ -49,13 +49,13 @@ conditions:
{% for step in range(1, deploy_steps_max) %}
WorkflowTasks_Step{{step}}_Enabled:
or:
- {% for role in roles %}
+ {%- for role in roles %}
- not:
equals:
- get_param: [role_data, {{role.name}}, service_workflow_tasks, step{{step}}]
- ''
- False
- {% endfor %}
+ {%- endfor %}
{% endfor %}
resources:
@@ -97,16 +97,16 @@ resources:
type: OS::Mistral::Workflow
condition: WorkflowTasks_Step{{step}}_Enabled
depends_on:
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {list_join: [".", ["tripleo", {get_param: stack_name}, "workflowtasks", "step{{step}}"]]}
type: direct
@@ -114,9 +114,9 @@ resources:
yaql:
expression: $.data.where($ != '').select($.get('step{{step}}')).where($ != null).flatten()
data:
- {% for role in roles %}
+ {%- for role in roles %}
- get_param: [role_data, {{role.name}}, service_workflow_tasks]
- {% endfor %}
+ {%- endfor %}
WorkflowTasks_Step{{step}}_Execution:
type: OS::Mistral::ExternalResource
@@ -130,18 +130,18 @@ resources:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
UPDATE:
workflow: { get_resource: WorkflowTasks_Step{{step}} }
params:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
always_update: true
# END service_workflow_tasks handling
{% endfor %}
@@ -270,7 +270,6 @@ resources:
update_identifier: {get_param: DeployIdentifier}
{% for step in range(1, deploy_steps_max) %}
-
{{role.name}}Deployment_Step{{step}}:
type: OS::Heat::StructuredDeploymentGroup
depends_on:
@@ -280,16 +279,16 @@ resources:
# WorkflowTasks_StepX resource and can be remove
# if https://bugs.launchpad.net/heat/+bug/1700569
# is fixed.
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {{role.name}}Deployment_Step{{step}}
servers: {get_param: [servers, {{role.name}}]}
@@ -300,7 +299,6 @@ resources:
update_identifier: {get_param: DeployIdentifier}
bootstrap_server_id: {get_param: [servers, {{primary_role_name}}, '0']}
docker_puppet_debug: {get_param: DockerPuppetDebug}
-
{% endfor %}
# END CONFIG STEPS
@@ -309,9 +307,9 @@ resources:
# after all the previous deployment steps.
{{role.name}}ExtraConfigPost:
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step5
- {% endfor %}
+ {%- endfor %}
type: OS::TripleO::NodeExtraConfigPost
properties:
servers: {get_param: [servers, {{role.name}}]}
@@ -322,9 +320,9 @@ resources:
{{role.name}}PostConfig:
type: OS::TripleO::Tasks::{{role.name}}PostConfig
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}ExtraConfigPost
- {% endfor %}
+ {%- endfor %}
properties:
servers: {get_param: servers}
input_values:
diff --git a/overcloud.j2.yaml b/overcloud.j2.yaml
index f18a0538..ddf2701a 100644
--- a/overcloud.j2.yaml
+++ b/overcloud.j2.yaml
@@ -60,13 +60,23 @@ parameters:
description: |
Additional hiera configuration to inject into the cluster.
type: json
-{% for role in roles %}
+{%- for role in roles %}
{{role.name}}ExtraConfig:
default: {}
description: |
Role specific additional hiera configuration to inject into the cluster.
type: json
-{% endfor %}
+{%- endfor %}
+ controllerExtraConfig:
+ default: {}
+ description: |
+ DEPRECATED use ControllerExtraConfig instead
+ type: json
+ NovaComputeExtraConfig:
+ default: {}
+ description: |
+ DEPRECATED use ComputeExtraConfig instead
+ type: json
InternalApiVirtualFixedIPs:
default: []
description: >
@@ -166,7 +176,6 @@ parameters:
{% else %}
default: "%stackname%-{{role.name.lower()}}-%index%"
{% endif %}
-
{{role.name}}RemovalPolicies:
default: []
type: json
@@ -215,6 +224,13 @@ parameters:
description: >
List of server hostnames to blacklist from any triggered deployments.
+parameter_groups:
+- label: deprecated
+ description: Do not use deprecated params, they will be removed.
+ parameters:
+ - controllerExtraConfig
+ - NovaComputeExtraConfig
+
conditions:
add_vips_to_etc_hosts: {equals : [{get_param: AddVipsToEtcHosts}, True]}
@@ -373,7 +389,17 @@ resources:
map_merge:
- get_attr: [{{role.name}}ServiceConfigSettings, value]
- get_param: ExtraConfig
+ {%- if role.name == 'Controller' %}
+ - map_merge:
+ - get_param: controllerExtraConfig
+ - get_param: {{role.name}}ExtraConfig
+ {%- elif role.name == 'Compute' %}
+ - map_merge:
+ - get_param: NovaComputeExtraConfig
+ - get_param: {{role.name}}ExtraConfig
+ {%- else %}
- get_param: {{role.name}}ExtraConfig
+ {%- endif %}
# Filter any null/None service_names which may be present due to mapping
# of services to OS::Heat::None
diff --git a/puppet/puppet-steps.j2 b/puppet/puppet-steps.j2
index 55aa6856..3d071018 100644
--- a/puppet/puppet-steps.j2
+++ b/puppet/puppet-steps.j2
@@ -1,16 +1,15 @@
{% set deploy_steps_max = 6 %}
-
conditions:
{% for step in range(1, deploy_steps_max) %}
WorkflowTasks_Step{{step}}_Enabled:
or:
- {% for role in roles %}
+ {%- for role in roles %}
- not:
equals:
- get_param: [role_data, {{role.name}}, service_workflow_tasks, step{{step}}]
- ''
- False
- {% endfor %}
+ {%- endfor %}
{% endfor %}
resources:
@@ -50,16 +49,16 @@ resources:
# WorkflowTasks_StepX resource and can be remove
# if https://bugs.launchpad.net/heat/+bug/1700569
# is fixed.
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {{role.name}}Deployment_Step{{step}}
servers: {get_param: [servers, {{role.name}}]}
@@ -74,9 +73,9 @@ resources:
# after all the previous deployment steps.
{{role.name}}ExtraConfigPost:
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step5
- {% endfor %}
+ {%- endfor %}
type: OS::TripleO::NodeExtraConfigPost
properties:
servers: {get_param: [servers, {{role.name}}]}
@@ -87,9 +86,9 @@ resources:
{{role.name}}PostConfig:
type: OS::TripleO::Tasks::{{role.name}}PostConfig
depends_on:
- {% for dep in roles %}
+ {%- for dep in roles %}
- {{dep.name}}ExtraConfigPost
- {% endfor %}
+ {%- endfor %}
properties:
servers: {get_param: servers}
input_values:
@@ -104,16 +103,16 @@ resources:
type: OS::Mistral::Workflow
condition: WorkflowTasks_Step{{step}}_Enabled
depends_on:
- {% if step == 1 %}
- {% for dep in roles %}
+ {%- if step == 1 %}
+ {%- for dep in roles %}
- {{dep.name}}PreConfig
- {{dep.name}}ArtifactsDeploy
- {% endfor %}
- {% else %}
- {% for dep in roles %}
+ {%- endfor %}
+ {%- else %}
+ {%- for dep in roles %}
- {{dep.name}}Deployment_Step{{step -1}}
- {% endfor %}
- {% endif %}
+ {%- endfor %}
+ {%- endif %}
properties:
name: {list_join: [".", ["tripleo", {get_param: stack_name}, "workflowtasks", "step{{step}}"]]}
type: direct
@@ -121,9 +120,9 @@ resources:
yaql:
expression: $.data.where($ != '').select($.get('step{{step}}')).where($ != null).flatten()
data:
- {% for role in roles %}
+ {%- for role in roles %}
- get_param: [role_data, {{role.name}}, service_workflow_tasks]
- {% endfor %}
+ {%- endfor %}
WorkflowTasks_Step{{step}}_Execution:
type: OS::Mistral::ExternalResource
@@ -137,18 +136,18 @@ resources:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
UPDATE:
workflow: { get_resource: WorkflowTasks_Step{{step}} }
params:
env:
service_ips: { get_param: ctlplane_service_ips }
role_merged_configs:
- {% for r in roles %}
+ {%- for r in roles %}
{{r.name}}: {get_param: [role_data, {{r.name}}, merged_config_settings]}
- {% endfor %}
+ {%- endfor %}
always_update: true
{% endfor %}
# END service_workflow_tasks handling