2 # Cookbook Name:: stateofthemap
5 # Copyright 2013, OpenStreetMap Foundation
7 # Licensed under the Apache License, Version 2.0 (the "License");
8 # you may not use this file except in compliance with the License.
9 # You may obtain a copy of the License at
11 # http://www.apache.org/licenses/LICENSE-2.0
13 # Unless required by applicable law or agreed to in writing, software
14 # distributed under the License is distributed on an "AS IS" BASIS,
15 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 # See the License for the specific language governing permissions and
17 # limitations under the License.
20 include_recipe "wordpress"
22 passwords = data_bag_item("stateofthemap", "passwords")
24 git "/srv/stateofthemap.org" do
26 repository "git://git.openstreetmap.org/stateofthemap.git"
32 ssl_certificate "stateofthemap.org" do
33 domains ["stateofthemap.org", "www.stateofthemap.org",
34 "stateofthemap.com", "www.stateofthemap.com"]
35 notifies :reload, "service[apache2]"
38 apache_site "stateofthemap.org" do
40 directory "/srv/stateofthemap.org"
43 directory "/srv/2007.stateofthemap.org" do
49 wordpress_site "2007.stateofthemap.org" do
50 aliases "2007.stateofthemap.com"
51 directory "/srv/2007.stateofthemap.org/wp"
53 database_name "sotm2007"
54 database_user "sotm2007"
55 database_password passwords["sotm2007"]
56 database_prefix "wp_sotm_"
59 wordpress_theme "2007.stateofthemap.org-refreshwp-11" do
61 site "2007.stateofthemap.org"
62 repository "git://git.openstreetmap.org/stateofthemap.git"
66 wordpress_plugin "2007.stateofthemap.org-geopress" do
68 site "2007.stateofthemap.org"
71 directory "/srv/2008.stateofthemap.org" do
77 wordpress_site "2008.stateofthemap.org" do
78 aliases "2008.stateofthemap.com"
79 directory "/srv/2008.stateofthemap.org/wp"
81 database_name "sotm2008"
82 database_user "sotm2008"
83 database_password passwords["sotm2008"]
84 database_prefix "wp_sotm08_"
87 wordpress_theme "2008.stateofthemap.org-refreshwp-11" do
89 site "2008.stateofthemap.org"
90 repository "git://git.openstreetmap.org/stateofthemap.git"
94 wordpress_plugin "2008.stateofthemap.org-geopress" do
96 site "2008.stateofthemap.org"
99 directory "/srv/2009.stateofthemap.org" do
105 git "/srv/2009.stateofthemap.org" do
107 repository "git://git.openstreetmap.org/stateofthemap.git"
108 revision "resources-2009"
113 wordpress_site "2009.stateofthemap.org" do
114 aliases "2009.stateofthemap.com"
115 directory "/srv/2009.stateofthemap.org/wp"
117 database_name "sotm2009"
118 database_user "sotm2009"
119 database_password passwords["sotm2009"]
120 urls "/register" => "/srv/2009.stateofthemap.org/register",
121 "/register-pro-user" => "/srv/2009.stateofthemap.org/register-pro-user",
122 "/podcasts" => "/srv/2009.stateofthemap.org/podcasts"
125 wordpress_theme "2009.stateofthemap.org-aerodrome" do
127 site "2009.stateofthemap.org"
128 repository "git://git.openstreetmap.org/stateofthemap.git"
129 revision "theme-2009"
132 wordpress_plugin "2009.stateofthemap.org-wp-sticky" do
134 site "2009.stateofthemap.org"
137 directory "/srv/2010.stateofthemap.org" do
143 git "/srv/2010.stateofthemap.org" do
145 repository "git://git.openstreetmap.org/stateofthemap.git"
146 revision "resources-2010"
151 wordpress_site "2010.stateofthemap.org" do
152 aliases "2010.stateofthemap.com"
153 directory "/srv/2010.stateofthemap.org/wp"
155 database_name "sotm2010"
156 database_user "sotm2010"
157 database_password passwords["sotm2010"]
158 urls "/register" => "/srv/2010.stateofthemap.org/register"
161 wordpress_theme "2010.stateofthemap.org-aerodrome" do
163 site "2010.stateofthemap.org"
164 repository "git://git.openstreetmap.org/stateofthemap.git"
165 revision "theme-2010"
168 wordpress_plugin "2010.stateofthemap.org-sitepress-multilingual-cms" do
169 name "sitepress-multilingual-cms"
170 site "2010.stateofthemap.org"
171 repository "git://chef.openstreetmap.org/sitepress-multilingual-cms.git"
174 wordpress_plugin "2010.stateofthemap.org-wp-sticky" do
176 site "2010.stateofthemap.org"
179 directory "/srv/2011.stateofthemap.org" do
185 git "/srv/2011.stateofthemap.org" do
187 repository "git://git.openstreetmap.org/stateofthemap.git"
188 revision "resources-2011"
193 wordpress_site "2011.stateofthemap.org" do
194 aliases "2011.stateofthemap.com"
195 directory "/srv/2011.stateofthemap.org/wp"
197 database_name "sotm2011"
198 database_user "sotm2011"
199 database_password passwords["sotm2011"]
200 urls "/register" => "/srv/2011.stateofthemap.org/register"
203 wordpress_theme "2011.stateofthemap.org-aerodrome" do
205 site "2011.stateofthemap.org"
206 repository "git://git.openstreetmap.org/stateofthemap.git"
207 revision "theme-2011"
210 wordpress_plugin "2011.stateofthemap.org-sitepress-multilingual-cms" do
211 name "sitepress-multilingual-cms"
212 site "2011.stateofthemap.org"
213 repository "git://chef.openstreetmap.org/sitepress-multilingual-cms.git"
216 wordpress_plugin "2011.stateofthemap.org-wp-sticky" do
218 site "2011.stateofthemap.org"
221 directory "/srv/2012.stateofthemap.org" do
227 git "/srv/2012.stateofthemap.org" do
229 repository "git://git.openstreetmap.org/stateofthemap.git"
230 revision "resources-2012"
235 wordpress_site "2012.stateofthemap.org" do
236 aliases "2012.stateofthemap.com"
237 directory "/srv/2012.stateofthemap.org/wp"
239 database_name "sotm2012"
240 database_user "sotm2012"
241 database_password passwords["sotm2012"]
242 urls "/register" => "/srv/2012.stateofthemap.org/register"
245 wordpress_theme "2012.stateofthemap.org-aerodrome" do
247 site "2012.stateofthemap.org"
248 repository "git://git.openstreetmap.org/stateofthemap.git"
249 revision "theme-2012"
252 wordpress_plugin "2012.stateofthemap.org-leaflet-maps-marker" do
253 name "leaflet-maps-marker"
254 site "2012.stateofthemap.org"
257 wordpress_plugin "2012.stateofthemap.org-sitepress-multilingual-cms" do
258 name "sitepress-multilingual-cms"
259 site "2012.stateofthemap.org"
260 repository "git://chef.openstreetmap.org/sitepress-multilingual-cms.git"
263 wordpress_plugin "2012.stateofthemap.org-wp-sticky" do
265 site "2012.stateofthemap.org"
268 template "/etc/cron.daily/sotm-backup" do
269 source "backup.cron.erb"
273 variables :passwords => passwords