Allows for customization of NetworkDeployment actions
authorGiulio Fidente <gfidente@redhat.com>
Fri, 20 Nov 2015 17:14:03 +0000 (18:14 +0100)
committerGiulio Fidente <gfidente@redhat.com>
Fri, 20 Nov 2015 19:49:56 +0000 (20:49 +0100)
We don't necessarily want the network configuration to be reapplied
with every template update so we add a param to configure on which
action the NetworkDeployment resource should be executed.

Change-Id: I0e86318eb5521e540cc567ce9d77e1060086d48b
Co-Authored-By: Dan Sneddon <dsneddon@redhat.com>
Co-Authored-By: James Slagle <jslagle@redhat.com>
Co-Authored-By: Jiri Stransky <jstransk@redhat.com>
Co-Authored-By: Steven Hardy <shardy@redhat.com>
puppet/ceph-storage.yaml
puppet/cinder-storage.yaml
puppet/compute.yaml
puppet/controller.yaml
puppet/swift-storage.yaml

index 0d96850..0bf0fde 100644 (file)
@@ -54,7 +54,11 @@ parameters:
     description: |
       Role specific additional hiera configuration to inject into the cluster.
     type: json
-
+  NetworkDeploymentActions:
+    type: comma_delimited_list
+    description: >
+      Heat action when to apply network configuration changes
+    default: ['CREATE']
 
 resources:
   CephStorage:
@@ -126,6 +130,7 @@ resources:
     properties:
       config: {get_resource: NetworkConfig}
       server: {get_resource: CephStorage}
+      actions: {get_param: NetworkDeploymentActions}
 
   CephStorageDeployment:
     type: OS::Heat::StructuredDeployment
index b536418..b500e43 100644 (file)
@@ -107,6 +107,11 @@ parameters:
   MysqlVirtualIP:
     type: string
     default: ''
+  NetworkDeploymentActions:
+    type: comma_delimited_list
+    description: >
+      Heat action when to apply network configuration changes
+    default: ['CREATE']
 
 resources:
   BlockStorage:
@@ -178,6 +183,7 @@ resources:
     properties:
       config: {get_resource: NetworkConfig}
       server: {get_resource: BlockStorage}
+      actions: {get_param: NetworkDeploymentActions}
 
   BlockStorageDeployment:
     type: OS::Heat::StructuredDeployment
index c147a0f..6ae3913 100644 (file)
@@ -273,6 +273,11 @@ parameters:
   Hostname:
     type: string
     default: '' # Defaults to Heat created hostname
+  NetworkDeploymentActions:
+    type: comma_delimited_list
+    description: >
+      Heat action when to apply network configuration changes
+    default: ['CREATE']
 
 resources:
 
@@ -347,6 +352,7 @@ resources:
     properties:
       config: {get_resource: NetworkConfig}
       server: {get_resource: NovaCompute}
+      actions: {get_param: NetworkDeploymentActions}
       input_values:
         bridge_name: {get_param: NeutronPhysicalBridge}
         interface_name: {get_param: NeutronPublicInterface}
index 2e8c312..0c921eb 100644 (file)
@@ -606,6 +606,11 @@ parameters:
   Hostname:
     type: string
     default: '' # Defaults to Heat created hostname
+  NetworkDeploymentActions:
+    type: comma_delimited_list
+    description: >
+      Heat action when to apply network configuration changes
+    default: ['CREATE']
 
 resources:
 
@@ -702,6 +707,7 @@ resources:
     properties:
       config: {get_resource: NetworkConfig}
       server: {get_resource: Controller}
+      actions: {get_param: NetworkDeploymentActions}
       input_values:
         bridge_name: br-ex
         interface_name: {get_param: NeutronPublicInterface}
index 3d9b901..19a7c7a 100644 (file)
@@ -77,7 +77,11 @@ parameters:
     description: |
       Role specific additional hiera configuration to inject into the cluster.
     type: json
-
+  NetworkDeploymentActions:
+    type: comma_delimited_list
+    description: >
+      Heat action when to apply network configuration changes
+    default: ['CREATE']
 
 resources:
 
@@ -149,6 +153,7 @@ resources:
     properties:
       config: {get_resource: NetworkConfig}
       server: {get_resource: SwiftStorage}
+      actions: {get_param: NetworkDeploymentActions}
 
   SwiftStorageHieraConfig:
     type: OS::Heat::StructuredConfig