Add CephExternal role for ceph-ansible
[apex-tripleo-heat-templates.git] / docker / services / nova-conductor.yaml
index d3696f0..17d137c 100644 (file)
@@ -15,6 +15,10 @@ parameters:
     description: Mapping of service endpoint -> protocol. Typically set
                  via parameter_defaults in the resource registry.
     type: json
+  ServiceData:
+    default: {}
+    description: Dictionary packing service data
+    type: json
   ServiceNetMap:
     default: {}
     description: Mapping of service_name -> network name. Typically set
@@ -32,17 +36,24 @@ parameters:
     default: {}
     description: Parameters specific to the role
     type: json
-
+  UpgradeLevelNovaCompute:
+    type: string
+    description: Nova Compute upgrade level
+    default: ''
 
 resources:
 
   ContainersCommon:
     type: ./containers-common.yaml
 
+  MySQLClient:
+    type: ../../puppet/services/database/mysql-client.yaml
+
   NovaConductorBase:
     type: ../../puppet/services/nova-conductor.yaml
     properties:
       EndpointMap: {get_param: EndpointMap}
+      ServiceData: {get_param: ServiceData}
       ServiceNetMap: {get_param: ServiceNetMap}
       DefaultPasswords: {get_param: DefaultPasswords}
       RoleName: {get_param: RoleName}
@@ -55,7 +66,10 @@ outputs:
       service_name: {get_attr: [NovaConductorBase, role_data, service_name]}
       config_settings: {get_attr: [NovaConductorBase, role_data, config_settings]}
       step_config: &step_config
-        get_attr: [NovaConductorBase, role_data, step_config]
+        list_join:
+          - "\n"
+          - - {get_attr: [NovaConductorBase, role_data, step_config]}
+            - {get_attr: [MySQLClient, role_data, step_config]}
       service_config_settings: {get_attr: [NovaConductorBase, role_data, service_config_settings]}
       # BEGIN DOCKER SETTINGS
       puppet_config:
@@ -97,6 +111,13 @@ outputs:
             path: /var/log/containers/nova
             state: directory
       upgrade_tasks:
+        - name: Set compute upgrade level to auto
+          tags: step1
+          ini_file:
+            str_replace:
+              template: "dest=/etc/nova/nova.conf section=upgrade_levels option=compute value=LEVEL"
+              params:
+                LEVEL: {get_param: UpgradeLevelNovaCompute}
         - name: Stop and disable nova_conductor service
           tags: step2
           service: name=openstack-nova-conductor state=stopped enabled=no