memcached (openstack) is no longer in use
[mirror/dsa-puppet.git] / 3rdparty / modules / nova / examples / nova_with_pacemaker.pp
1 # Example: managing nova compute controller services with pacemaker
2 #
3 # By setting enabled to false, these services will not be started at boot.  By setting
4 # manage_service to false, puppet will not kill these services on every run.  This
5 # allows the Pacemaker resource manager to dynamically determine on which node each
6 # service should run.
7 #
8 # The puppet commands below would ideally be applied to at least three nodes.
9 #
10 # Note that nova-api and nova-novncproxy are associated with the virtual IP address as
11 # they are called from external services.  The remaining services connect to the
12 # database and/or message broker independently.
13 #
14 # Example pacemaker resource configuration commands (configured once per cluster):
15 #
16 # sudo pcs resource create nova_vip ocf:heartbeat:IPaddr2 params ip=192.0.2.3 \
17 #   cidr_netmask=24 op monitor interval=10s
18 #
19 # sudo pcs resource create nova_api_service lsb:openstack-nova-api
20 # sudo pcs resource create nova_conductor_service lsb:openstack-nova-conductor
21 # sudo pcs resource create nova_consoleauth_service lsb:openstack-nova-consoleauth
22 # sudo pcs resource create nova_novncproxy_service lsb:openstack-nova-novncproxy
23 # sudo pcs resource create nova_scheduler_service lsb:openstack-nova-scheduler
24 #
25 # sudo pcs constraint colocation add nova_api_service with nova_vip
26 # sudo pcs constraint colocation add nova_novncproxy_service with nova_vip
27
28 class { 'nova': }
29
30 class { 'nova::api':
31   enabled           => false,
32   manage_service    => false,
33   admin_password    => 'PASSWORD',
34 }
35
36 class { 'nova::conductor':
37   enabled        => false,
38   manage_service => false,
39 }
40
41 class { 'nova::consoleauth':
42   enabled        => false,
43   manage_service => false,
44 }
45
46 class { 'nova::scheduler':
47   enabled        => false,
48   manage_service => false,
49 }
50
51 class { 'nova::vncproxy':
52   enabled        => false,
53   manage_service => false,
54 }
55