aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Prince <dprince@redhat.com>2015-02-19 15:54:24 -0800
committerDan Prince <dprince@redhat.com>2015-02-23 20:45:01 -0500
commitb11ac7e6b67c08eb7407872ece519f2675151483 (patch)
treee9671adf67ea1f6fa326400a435a3ad3b977b47e
parent62ab434139c4576afe84b7b0b08374261fc79563 (diff)
Compute: Exec puppet after all configuration
This patch adds a new ComputeNodesPostDeployment resource which can be used along with the environment file to specify a nested stack which is guaranteed to execute after all the Compute config deployments have executed. This is really useful for Puppet in that Heat actually controls where puppet executes in the deployment process and we want to ensure puppet runs after all hiera configuration data has be deployed to the nodes. With the previous approach some of the data would be there, but allNodes data would not be guaranteed to be there in time. As os-apply-config (tripleo-image-elements) have their ordering controlled within the elements themselves an empty stubbed in nested stack has been added so that we don't break that implementation. Change-Id: I80bccd692e45393f8250607073d1fe7beb0d7396
-rw-r--r--compute-post.yaml8
-rw-r--r--overcloud-resource-registry-puppet.yaml1
-rw-r--r--overcloud-resource-registry.yaml1
-rw-r--r--overcloud-without-mergepy.yaml6
-rw-r--r--puppet/compute-post-puppet.yaml25
-rw-r--r--puppet/compute-puppet.yaml15
6 files changed, 41 insertions, 15 deletions
diff --git a/compute-post.yaml b/compute-post.yaml
new file mode 100644
index 00000000..8c49709f
--- /dev/null
+++ b/compute-post.yaml
@@ -0,0 +1,8 @@
+heat_template_version: 2014-10-16
+description: 'Compute Post Deployment'
+# NOTE: this is a noop for os-apply-config style deployments because
+# post deployment ordering is controlled by tripleo-image-elements
+
+parameters:
+ servers:
+ type: json
diff --git a/overcloud-resource-registry-puppet.yaml b/overcloud-resource-registry-puppet.yaml
index b487f425..eeef6d1c 100644
--- a/overcloud-resource-registry-puppet.yaml
+++ b/overcloud-resource-registry-puppet.yaml
@@ -7,6 +7,7 @@ resource_registry:
OS::TripleO::Net::SoftwareConfig: net-config-bridge.yaml
OS::TripleO::CephStorage: puppet/ceph-storage-puppet.yaml
OS::TripleO::ControllerPostDeployment: puppet/controller-post-puppet.yaml
+ OS::TripleO::ComputePostDeployment: puppet/compute-post-puppet.yaml
OS::TripleO::SwiftDevicesAndProxy::SoftwareConfig: puppet/swift-devices-and-proxy-config.yaml
OS::TripleO::AllNodes::SoftwareConfig: puppet/all-nodes-config.yaml
OS::TripleO::BootstrapNode::SoftwareConfig: puppet/bootstrap-config.yaml
diff --git a/overcloud-resource-registry.yaml b/overcloud-resource-registry.yaml
index 32e3ad4a..9d0f653e 100644
--- a/overcloud-resource-registry.yaml
+++ b/overcloud-resource-registry.yaml
@@ -7,6 +7,7 @@ resource_registry:
OS::TripleO::Net::SoftwareConfig: net-config-noop.yaml
OS::TripleO::CephStorage: ceph-storage.yaml
OS::TripleO::ControllerPostDeployment: controller-post.yaml
+ OS::TripleO::ComputePostDeployment: compute-post.yaml
OS::TripleO::SwiftDevicesAndProxy::SoftwareConfig: swift-devices-and-proxy-config.yaml
OS::TripleO::AllNodes::SoftwareConfig: all-nodes-config.yaml
OS::TripleO::BootstrapNode::SoftwareConfig: bootstrap-config.yaml
diff --git a/overcloud-without-mergepy.yaml b/overcloud-without-mergepy.yaml
index bd48ec66..3a719e3c 100644
--- a/overcloud-without-mergepy.yaml
+++ b/overcloud-without-mergepy.yaml
@@ -784,6 +784,12 @@ resources:
properties:
servers: {get_attr: [Controller, attributes, nova_server_resource]}
+ ComputeNodesPostDeployment:
+ type: OS::TripleO::ComputePostDeployment
+ depends_on: ComputeAllNodesDeployment
+ properties:
+ servers: {get_attr: [Compute, attributes, nova_server_resource]}
+
outputs:
KeystoneURL:
description: URL for the Overcloud Keystone service
diff --git a/puppet/compute-post-puppet.yaml b/puppet/compute-post-puppet.yaml
new file mode 100644
index 00000000..9b7eb0cf
--- /dev/null
+++ b/puppet/compute-post-puppet.yaml
@@ -0,0 +1,25 @@
+heat_template_version: 2014-10-16
+
+description: >
+ OpenStack compute node post deployment for Puppet.
+
+parameters:
+ servers:
+ type: json
+
+resources:
+
+ ComputePuppetConfig:
+ type: OS::Heat::SoftwareConfig
+ properties:
+ group: puppet
+ outputs:
+ - name: result
+ config:
+ get_file: manifests/overcloud_compute.pp
+
+ ComputePuppetDeployment:
+ type: OS::Heat::StructuredDeployments
+ properties:
+ servers: {get_param: servers}
+ config: {get_resource: ComputePuppetConfig}
diff --git a/puppet/compute-puppet.yaml b/puppet/compute-puppet.yaml
index ab2d0a32..e6b5a78b 100644
--- a/puppet/compute-puppet.yaml
+++ b/puppet/compute-puppet.yaml
@@ -260,21 +260,6 @@ resources:
bridge_name: {get_param: NeutronPhysicalBridge}
interface_name: {get_param: NeutronPublicInterface}
- ComputePuppetConfig:
- type: OS::Heat::SoftwareConfig
- properties:
- group: puppet
- outputs:
- - name: result
- config:
- get_file: manifests/overcloud_compute.pp
-
- ComputePuppetDeployment:
- type: OS::Heat::StructuredDeployment
- properties:
- server: {get_resource: NovaCompute}
- config: {get_resource: ComputePuppetConfig}
-
NovaComputeConfig:
type: OS::Heat::StructuredConfig
properties: