try again, with puppetforge modules, correctly included now
[mirror/dsa-puppet.git] / 3rdparty / modules / nova / manifests / conductor.pp
1 # == Class: nova::conductor
2 #
3 # Manages nova conductor package and service
4 #
5 # === Parameters:
6 #
7 # [*enabled*]
8 #   (optional) Whether to enable the nova-conductor service
9 #   Defaults to false
10 #
11 # [*manage_service*]
12 #   (optional) Whether to start/stop the service
13 #   Defaults to true
14 #
15 # [*ensure_package*]
16 #   (optional) The state of the nova conductor package
17 #   Defaults to 'present'
18 #
19 # [*workers*]
20 #   (optional) Number of workers for OpenStack Conductor service
21 #   Defaults to undef (i.e. parameter will not be present)
22 #
23 class nova::conductor(
24   $enabled        = false,
25   $manage_service = true,
26   $ensure_package = 'present',
27   $workers        = undef,
28 ) {
29
30   include nova::db
31   include nova::params
32
33   nova::generic_service { 'conductor':
34     enabled        => $enabled,
35     manage_service => $manage_service,
36     package_name   => $::nova::params::conductor_package_name,
37     service_name   => $::nova::params::conductor_service_name,
38     ensure_package => $ensure_package,
39   }
40
41   if $workers {
42     nova_config {
43       'conductor/workers': value => $workers;
44     }
45   }
46 }