]> git.donarmstrong.com Git - dsa-puppet.git/blob - 3rdparty/modules/nova/manifests/qpid.pp
try again, with puppetforge modules, correctly included now
[dsa-puppet.git] / 3rdparty / modules / nova / manifests / qpid.pp
1 # == Class: nova::qpid
2 #
3 # Class for installing qpid server for nova
4 #
5 # === Parameters:
6 #
7 # [*enabled*]
8 #   (optional) Whether to enable the service
9 #   Defaults to true
10 #
11 # [*user*]
12 #   (optional) The user to create in qpid
13 #   Defaults to 'guest'
14 #
15 # [*password*]
16 #   (optional) The password to create for the user
17 #   Defaults to 'guest'
18 #
19 # [*file*]
20 #   (optional) Sasl file for the user
21 #   Defaults to '/var/lib/qpidd/qpidd.sasldb'
22 #
23 # [*realm*]
24 #   (optional) Realm for the user
25 #   Defaults to 'OPENSTACK'
26 #
27 class nova::qpid(
28   $enabled  = true,
29   $user     = 'guest',
30   $password = 'guest',
31   $file     = '/var/lib/qpidd/qpidd.sasldb',
32   $realm    = 'OPENSTACK'
33 ) {
34
35   # only configure nova after the queue is up
36   Class['qpid::server'] -> Package<| title == 'nova-common' |>
37
38   if ($enabled) {
39     $service_ensure = 'running'
40
41     qpid_user { $user:
42       password  => $password,
43       file      => $file,
44       realm     => $realm,
45       provider  => 'saslpasswd2',
46       require   => Class['qpid::server'],
47     }
48
49   } else {
50     $service_ensure = 'stopped'
51   }
52
53   class { 'qpid::server':
54     service_ensure => $service_ensure
55   }
56
57 }