aboutsummaryrefslogtreecommitdiffstats
path: root/overcloud.j2.yaml
diff options
context:
space:
mode:
authorDan Prince <dprince@redhat.com>2016-10-10 21:03:12 -0400
committerDan Prince <dprince@redhat.com>2016-10-13 14:15:54 -0400
commit9f8944111c280de877326471899be23caca9bb94 (patch)
tree9163ed71503d46ba125a3f8f353f9cb7144f4bb2 /overcloud.j2.yaml
parent8f5ebd08c4816849f959ea8471ebe956b1e1f601 (diff)
Split out hosts config deployment
This patch moves the hosts configuration into its own deployment. It will continue to use os-apply-config as something that is required early on in the bootstrapping (it needs to be configured before puppet runs for example). The motivation here is so we can refactor all-nodes-config.yaml to use a new hiera hook that that avoids os-apply-config entirely. Change-Id: Ib3e4380f205358b27d22a1102b663cf300b1ed86 Partial-bug: #1596373
Diffstat (limited to 'overcloud.j2.yaml')
-rw-r--r--overcloud.j2.yaml30
1 files changed, 23 insertions, 7 deletions
diff --git a/overcloud.j2.yaml b/overcloud.j2.yaml
index db1a78bf..7e1f496c 100644
--- a/overcloud.j2.yaml
+++ b/overcloud.j2.yaml
@@ -214,8 +214,16 @@ resources:
EndpointMap: {get_attr: [EndpointMap, endpoint_map]}
DefaultPasswords: {get_attr: [DefaultPasswords, passwords]}
+ {{role.name}}HostsDeployment:
+ type: OS::Heat::StructuredDeployments
+ properties:
+ name: {{role.name}}HostsDeployment
+ config: {get_attr: [hostsConfig, config_id]}
+ servers: {get_attr: [{{role.name}}, attributes, nova_server_resource]}
+
{{role.name}}AllNodesDeployment:
type: OS::Heat::StructuredDeployments
+ depends_on: {{role.name}}HostsDeployment
properties:
name: {{role.name}}AllNodesDeployment
config: {get_attr: [allNodesConfig, config_id]}
@@ -303,6 +311,16 @@ resources:
MonitoringSubscriptions: {get_attr: [{{role.name}}ServiceChain, role_data, monitoring_subscriptions]}
{% endfor %}
+ hostsConfig:
+ type: OS::TripleO::Hosts::SoftwareConfig
+ properties:
+ hosts:
+{% for role in roles %}
+ - list_join:
+ - '\n'
+ - {get_attr: [{{role.name}}, hosts_entry]}
+{% endfor %}
+
allNodesConfig:
type: OS::TripleO::AllNodes::SoftwareConfig
properties:
@@ -311,12 +329,6 @@ resources:
cloud_name_storage: {get_param: CloudNameStorage}
cloud_name_storage_mgmt: {get_param: CloudNameStorageManagement}
cloud_name_ctlplane: {get_param: CloudNameCtlplane}
- hosts:
-{% for role in roles %}
- - list_join:
- - '\n'
- - {get_attr: [{{role.name}}, hosts_entry]}
-{% endfor %}
enabled_services:
list_join:
- ','
@@ -517,6 +529,10 @@ resources:
# Post deployment steps for all roles
AllNodesDeploySteps:
type: OS::TripleO::PostDeploySteps
+{% for role in roles %}
+ depends_on:
+ - {{role.name}}AllNodesDeployment
+{% endfor %}
properties:
servers:
{% for role in roles %}
@@ -599,7 +615,7 @@ outputs:
value:
list_join:
- "\n"
- - - {get_attr: [allNodesConfig, hosts_entries]}
+ - - {get_attr: [hostsConfig, hosts_entries]}
-
- str_replace:
template: IP HOST