Wire in hieradata overrides via ExtraConfig for ObjectStorage
authorSteven Hardy <shardy@redhat.com>
Thu, 16 Jul 2015 16:45:32 +0000 (17:45 +0100)
committerSteven Hardy <shardy@redhat.com>
Thu, 16 Jul 2015 16:55:48 +0000 (17:55 +0100)
Adds support for global (ExtraConfig) and role-specific
(ObjectStorageExtraConfig) hiera overrides, similar to those added
for the Controller, NovaCompute and BlockStorage roles.

Change-Id: I7dd0d8003017e2738366983cb5d8e08b3f3fa334

overcloud-without-mergepy.yaml
puppet/swift-storage-puppet.yaml
swift-storage.yaml

index f341672..1246706 100644 (file)
@@ -581,6 +581,13 @@ parameters:
   SwiftStorageImage:
     default: overcloud-swift-storage
     type: string
+  ObjectStorageExtraConfig:
+    default: {}
+    description: |
+      ObjectStorage specific configuration to inject into the cluster. Same
+      structure as ExtraConfig.
+    type: json
+
 
 # Ceph storage specific parameters
   CephStorageCount:
@@ -915,6 +922,8 @@ resources:
               template: {get_param: ObjectStorageHostnameFormat}
               params:
                 '%stackname%': {get_param: 'OS::stack_name'}
+          ExtraConfig: {get_param: ExtraConfig}
+          ObjectStorageExtraConfig: {get_param: ObjectStorageExtraConfig}
 
   CephStorage:
     type: OS::Heat::ResourceGroup
index fb1756b..0566405 100644 (file)
@@ -65,6 +65,18 @@ parameters:
   Hostname:
     type: string
     default: '' # Defaults to Heat created hostname
+  ExtraConfig:
+    default: {}
+    description: |
+      Additional hiera configuration to inject into the cluster. Note
+      that ObjectStorageExtraConfig takes precedence over ExtraConfig.
+    type: json
+  ObjectStorageExtraConfig:
+    default: {}
+    description: |
+      Role specific additional hiera configuration to inject into the cluster.
+    type: json
+
 
 resources:
 
@@ -126,6 +138,8 @@ resources:
         hiera:
           hierarchy:
             - heat_config_%{::deploy_config_name}
+            - object_extraconfig
+            - extraconfig
             - object
             - swift_devices_and_proxy # provided by SwiftDevicesAndProxyConfig
             - all_nodes # provided by allNodesConfig
@@ -134,6 +148,10 @@ resources:
           datafiles:
             common:
               raw_data: {get_file: hieradata/common.yaml}
+            object_extraconfig:
+              mapped_data: {get_param: ObjectStorageExtraConfig}
+            extraconfig:
+              mapped_data: {get_param: ExtraConfig}
             object:
               raw_data: {get_file: hieradata/object.yaml}
               mapped_data: # data supplied directly to this deployment configuration, etc
index e4cacf3..1a2967f 100644 (file)
@@ -39,6 +39,11 @@ parameters:
           }
         }
     type: json
+  ObjectStorageExtraConfig:
+    default: {}
+    description: |
+      Role specific additional configuration to inject into the cluster.
+    type: json
   Flavor:
     description: Flavor for Swift storage nodes to request when deploying.
     type: string