]> git.openstreetmap.org Git - chef.git/blob - roles/ironbelly.rb
Allow all tilecache servers to sync to the log store
[chef.git] / roles / ironbelly.rb
1 name "ironbelly"
2 description "Master role applied to ironbelly"
3
4 default_attributes(
5   :apt => {
6     :sources => [ "ubuntugis-unstable" ]
7   },
8   :networking => {
9     :interfaces => {
10       :internal_ipv4 => {
11         :interface => "eth0",
12         :role => :internal,
13         :family => :inet,
14         :address => "146.179.159.177"
15       },
16       :external_ipv4 => {
17         :interface => "eth1",
18         :role => :external,
19         :family => :inet,
20         :address => "193.63.75.107"
21       },
22       :external_ipv6 => {
23         :interface => "eth1",
24         :role => :external,
25         :family => :inet6,
26         :address => "2001:630:12:500:225:90ff:fec4:f6ef"
27       }
28     }
29   },
30   :openvpn => {
31     :address => "10.0.16.2",
32     :tunnels => {
33       :ic2ucl => {
34         :port => "1194",
35         :mode => "server",
36         :peer => {
37           :host => "ridley.openstreetmap.org"
38         }
39       }
40     }
41   },
42   :rsyncd => {
43     :modules => {
44       :hosts => {
45         :comment => "Host data",
46         :path => "/home/hosts",
47         :read_only => true,
48         :write_only => false,
49         :list => false,
50         :uid => "tomh",
51         :gid => "tomh",
52         :transfer_logging => false,
53         :hosts_allow => [ 
54           "89.16.179.150",                       # shenron
55           "2001:41c8:10:996:21d:7dff:fec3:df70", # shenron
56           "212.159.112.221"                      # grant
57         ]
58       },
59       :logs => {
60         :comment => "Log files",
61         :path => "/store/logs",
62         :read_only => false,
63         :write_only => true,
64         :list => false,
65         :uid => "www-data",
66         :gid => "www-data",
67         :transfer_logging => false,
68         :hosts_allow => [
69           "128.40.168.0/24",      # ucl external
70           "146.179.159.160/27",   # ic internal
71           "193.63.75.96/27",      # ic external
72           "2001:630:12:500::/64", # ic external
73           "127.0.0.0/8",          # localhost
74           "::1"                   # localhost
75         ],
76         :nodes_allow => "roles:tilecache"
77       }
78     }
79   }
80 );
81
82 run_list(
83   "role[ic]",
84   "role[gateway]",
85   "role[chef-server]",
86   "role[chef-repository]",
87   "role[web-storage]",
88   "role[supybot]",
89   "role[backup]",
90   "role[stats]",
91   "role[planet]",
92   "recipe[rsyncd]",
93   "recipe[openvpn]"
94 )