OSDN Git Service

refactor node_commons role.
[metasearch/grid-chef-repo.git] / roles / grid-gpm.rb
1 name 'grid-gpm'
2 description 'Grid provisioning master node'
3
4 run_list(
5   'role[node_commons]',
6   'role[ganglia-gmond]',
7 )
8
9 this_domain = 'grid.example.com'
10 mcast_addr = '239.2.10.5'
11 port = '8649'
12
13 #env_run_lists "prod" => ["recipe[apache2]"], "staging" => ["recipe[apache2::staging]"], "_default" => []
14
15 default_attributes(
16 )
17
18 override_attributes(
19   'ganglia' => {
20     # gmond
21     'cluster' => {
22       'name' => 'ProvisioningMaster',
23       'owner' => this_domain
24     },
25     # static multi-cast
26     'static' => {
27       'udp_send_channels' => [
28         {
29           'mcast_join' => mcast_addr,
30           'host' => '',
31           'port' => port,
32           'ttl' => '1'
33         }
34       ],
35       'udp_recv_channels' => [
36         {
37           'mcast_join' => mcast_addr,
38           'port' => port,
39           'bind' => mcast_addr
40         }
41       ]
42     }
43   }
44 )