Merge "Setting keystone region for congress"
[apex-tripleo-heat-templates.git] / puppet / services / nova-conductor.yaml
1 heat_template_version: ocata
2
3 description: >
4   OpenStack Nova Conductor service configured with Puppet
5
6 parameters:
7   ServiceNetMap:
8     default: {}
9     description: Mapping of service_name -> network name. Typically set
10                  via parameter_defaults in the resource registry.  This
11                  mapping overrides those in ServiceNetMapDefaults.
12     type: json
13   DefaultPasswords:
14     default: {}
15     type: json
16   EndpointMap:
17     default: {}
18     description: Mapping of service endpoint -> protocol. Typically set
19                  via parameter_defaults in the resource registry.
20     type: json
21   NovaWorkers:
22     default: 0
23     description: Number of workers for Nova Conductor service.
24     type: number
25   MonitoringSubscriptionNovaConductor:
26     default: 'overcloud-nova-conductor'
27     type: string
28   NovaSchedulerLoggingSource:
29     type: json
30     default:
31       tag: openstack.nova.scheduler
32       path: /var/log/nova/nova-scheduler.log
33   UpgradeLevelNovaCompute:
34     type: string
35     description: Nova Compute upgrade level
36     default: auto
37
38 conditions:
39   nova_workers_zero: {equals : [{get_param: NovaWorkers}, 0]}
40
41 resources:
42   NovaBase:
43     type: ./nova-base.yaml
44     properties:
45       ServiceNetMap: {get_param: ServiceNetMap}
46       DefaultPasswords: {get_param: DefaultPasswords}
47       EndpointMap: {get_param: EndpointMap}
48
49 outputs:
50   role_data:
51     description: Role data for the Nova Conductor service.
52     value:
53       service_name: nova_conductor
54       monitoring_subscription: {get_param: MonitoringSubscriptionNovaConductor}
55       logging_source: {get_param: NovaSchedulerLoggingSource}
56       logging_groups:
57         - nova
58       config_settings:
59         map_merge:
60         - get_attr: [NovaBase, role_data, config_settings]
61         -
62           if:
63           - nova_workers_zero
64           - {}
65           - nova::conductor::workers: {get_param: NovaWorkers}
66       step_config: |
67         include tripleo::profile::base::nova::conductor
68       upgrade_tasks:
69         - name: Stop nova_conductor service
70           tags: step1
71           service: name=openstack-nova-conductor state=stopped
72         # If not already set by puppet (e.g a pre-ocata version), set the
73         # upgrade_level for compute to "auto"
74         - name: Set compute upgrade level to auto
75           tags: step1
76           ini_file:
77             str_replace:
78               template: "dest=/etc/nova/nova.conf section=upgrade_levels option=compute value=LEVEL"
79               params:
80                 LEVEL: {get_param: UpgradeLevelNovaCompute}