]> git.openstreetmap.org Git - chef.git/blob - roles/tile.rb
poldi: Add munin voltage critical override
[chef.git] / roles / tile.rb
1 name "tile"
2 description "Role applied to all tile servers"
3
4 default_attributes(
5   :accounts => {
6     :users => {
7       :tile => {
8         :status => :role,
9         :members => [ :jburgess, :tomh ]
10       },
11     },
12   },
13   :apache => {
14     :mpm => "event",
15     :timeout => 60,
16     :event => {
17       :server_limit => 60,
18       :max_clients => 1200,
19       :threads_per_child => 20,
20       :min_spare_threads => 30,
21       :max_spare_threads => 180,
22       :max_requests_per_child => 100000
23     }
24   },
25   :apt => {
26     :sources => [ "ubuntugis-stable" ]
27   },
28   :postgresql => {
29     :versions => [ "9.1" ],
30     :settings => {
31       :defaults => {
32         :temp_buffers => "32MB",
33         :work_mem => "128MB",
34         :wal_buffers => "1024kB",
35         :wal_writer_delay => "500ms",
36         :commit_delay => "10000",
37         :checkpoint_segments => "60"
38       }
39     }
40   },
41   :sysctl => {
42     :sockets => {
43       :comment => "Increase size of connection queue",
44       :parameters => {
45         "net.core.somaxconn" => 10000
46       }
47     },
48     :kernel_scheduler_tune => {
49       :comment => "Tune kernel scheduler preempt",
50       :parameters => {
51         "kernel.sched_min_granularity_ns" => 10000000,
52         "kernel.sched_wakeup_granularity_ns" => 15000000
53       }
54     }
55   },
56   :tile => {
57     :database => {
58       :cluster => "9.1/main"
59     },
60     :data => {
61       :world_boundaries => {
62         :url => "http://planet.openstreetmap.org/historical-shapefiles/world_boundaries-spherical.tgz"
63       },
64       :simplified_land_polygons => {
65         :url => "http://data.openstreetmapdata.com/simplified-land-polygons-complete-3857.zip",
66         :refresh => true
67       },
68       :admin_boundaries => {
69         :url => "http://www.naturalearthdata.com/http//www.naturalearthdata.com/download/110m/cultural/ne_110m_admin_0_boundary_lines_land.zip",
70         :directory => "ne_110m_admin_0_boundary_lines_land"
71       },
72       :populated_places => {
73         :url => "http://www.naturalearthdata.com/http//www.naturalearthdata.com/download/10m/cultural/ne_10m_populated_places.zip",
74         :directory => "ne_10m_populated_places",
75         :original => "ne_10m_populated_places.shp",
76         :processed => "ne_10m_populated_places_fixed.shp"
77       },
78       :land_polygons => {
79         :url => "http://data.openstreetmapdata.com/land-polygons-split-3857.zip",
80         :refresh => true
81       }
82     },
83     :styles => {
84       :default => {
85         :repository => "git://github.com/gravitystorm/openstreetmap-carto.git",
86         :revision => "v2.10.1",
87         :max_zoom => 19
88       }
89     }
90   }
91 )
92
93 run_list(
94   "recipe[tile]"
95 )