Configure the thunderforest API key
authorTom Hughes <tom@compton.nu>
Thu, 8 Sep 2016 15:18:45 +0000 (16:18 +0100)
committerTom Hughes <tom@compton.nu>
Thu, 8 Sep 2016 15:18:45 +0000 (16:18 +0100)
cookbooks/web/definitions/rails_port.rb
cookbooks/web/recipes/rails.rb

index c23587d..dc39d44 100644 (file)
@@ -197,6 +197,10 @@ define :rails_port, :action => [:create, :enable] do
       line.gsub!(/^( *)#mapzen_valhalla_key:.*$/, "\\1mapzen_valhalla_key: \"#{params[:mapzen_valhalla_key]}\"")
     end
 
+    if params[:thunderforest_key]
+      line.gsub!(/^( *)#thunderforest_key:.*$/, "\\1thunderforest_key: \"#{params[:thunderforest_key]}\"")
+    end
+
     line.gsub!(/^( *)require_terms_seen:.*$/, "\\1require_terms_seen: true")
     line.gsub!(/^( *)require_terms_agreed:.*$/, "\\1require_terms_agreed: true")
 
index a388b21..52aa096 100644 (file)
@@ -79,6 +79,7 @@ rails_port "www.openstreetmap.org" do
   github_auth_id "acf7da34edee99e35499"
   github_auth_secret web_passwords["github_auth_secret"]
   mapzen_valhalla_key web_passwords["mapzen_valhalla_key"]
+  thunderforest_key web_passwords["thunderforest_key"]
 end
 
 package "libjson-xs-perl"