Merge "Add an upgrade task for redis service"
[apex-tripleo-heat-templates.git] / puppet / blockstorage-role.yaml
index 60ddeb8..95dcf0b 100644 (file)
@@ -69,8 +69,8 @@ parameters:
     default: 'localdomain'
     type: string
     description: >
     default: 'localdomain'
     type: string
     description: >
-      The DNS domain used for the hosts. This should match the dhcp_domain
-      configured in the Undercloud neutron. Defaults to localdomain.
+      The DNS domain used for the hosts. This must match the
+      overcloud_domain_name configured on the undercloud.
   BlockStorageServerMetadata:
     default: {}
     description: >
   BlockStorageServerMetadata:
     default: {}
     description: >
@@ -139,6 +139,10 @@ parameters:
       Map of server hostnames to blacklist from any triggered
       deployments. If the value is 1, the server will be blacklisted. This
       parameter is generated from the parent template.
       Map of server hostnames to blacklist from any triggered
       deployments. If the value is 1, the server will be blacklisted. This
       parameter is generated from the parent template.
+  RoleParameters:
+    type: json
+    description: Role Specific Parameters
+    default: {}
 
 conditions:
   server_not_blacklisted:
 
 conditions:
   server_not_blacklisted:
@@ -372,6 +376,8 @@ resources:
     type: OS::TripleO::BlockStorage::PreNetworkConfig
     properties:
       server: {get_resource: BlockStorage}
     type: OS::TripleO::BlockStorage::PreNetworkConfig
     properties:
       server: {get_resource: BlockStorage}
+      RoleParameters: {get_param: RoleParameters}
+      deployment_actions: {get_attr: [DeploymentActions, value]}
 
   NetworkDeployment:
     type: OS::TripleO::SoftwareDeployment
 
   NetworkDeployment:
     type: OS::TripleO::SoftwareDeployment
@@ -466,6 +472,7 @@ resources:
             fqdn_tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
             fqdn_management: {get_attr: [NetHostMap, value, management, fqdn]}
             fqdn_ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
             fqdn_tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
             fqdn_management: {get_attr: [NetHostMap, value, management, fqdn]}
             fqdn_ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
+            fqdn_external: {get_attr: [NetHostMap, value, external, fqdn]}
 
   # Resource for site-specific injection of root certificate
   NodeTLSCAData:
 
   # Resource for site-specific injection of root certificate
   NodeTLSCAData:
@@ -479,6 +486,9 @@ resources:
   NodeExtraConfig:
     depends_on: NodeTLSCAData
     type: OS::TripleO::NodeExtraConfig
   NodeExtraConfig:
     depends_on: NodeTLSCAData
     type: OS::TripleO::NodeExtraConfig
+    # We have to use conditions here so that we don't break backwards
+    # compatibility with templates everywhere
+    condition: server_not_blacklisted
     properties:
         server: {get_resource: BlockStorage}
 
     properties:
         server: {get_resource: BlockStorage}
 
@@ -501,11 +511,21 @@ resources:
           - ['CREATE', 'UPDATE']
           - []
 
           - ['CREATE', 'UPDATE']
           - []
 
+  DeploymentActions:
+    type: OS::Heat::Value
+    properties:
+      value:
+        if:
+          - server_not_blacklisted
+          - ['CREATE', 'UPDATE']
+          - []
+
   SshHostPubKey:
     type: OS::TripleO::Ssh::HostPubKey
     depends_on: BlockStorageDeployment
     properties:
         server: {get_resource: BlockStorage}
   SshHostPubKey:
     type: OS::TripleO::Ssh::HostPubKey
     depends_on: BlockStorageDeployment
     properties:
         server: {get_resource: BlockStorage}
+        deployment_actions: {get_attr: [DeploymentActions, value]}
 
 outputs:
   ip_address:
 
 outputs:
   ip_address: