]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/tile/recipes/default.rb
Fix some rubocop detected style issues
[chef.git] / cookbooks / tile / recipes / default.rb
index 6cb1b9acbd21620ee2f96a0f6092094856aceb96..fc4feb0b63fe19eeefffb68fbb6d5685f9d5b588 100644 (file)
@@ -145,7 +145,7 @@ directory "/srv/tile.openstreetmap.org/data" do
   mode 0755
 end
 
-node[:tile][:data].each do |name,data|
+node[:tile][:data].each_value do |data|
   url = data[:url]
   file = "/srv/tile.openstreetmap.org/data/#{File.basename(url)}"
   directory = "/srv/tile.openstreetmap.org/data/#{data[:directory]}"
@@ -213,7 +213,7 @@ node[:tile][:data].each do |name,data|
       action :create
       use_conditional_get true
     else
-      action :create_if_missing 
+      action :create_if_missing
     end
 
     source url
@@ -235,7 +235,7 @@ directory "/srv/tile.openstreetmap.org/styles" do
   mode 0755
 end
 
-node[:tile][:styles].each do |name,details|
+node[:tile][:styles].each do |name, details|
   style_directory = "/srv/tile.openstreetmap.org/styles/#{name}"
   tile_directory = "/srv/tile.openstreetmap.org/tiles/#{name}"
 
@@ -355,8 +355,8 @@ end
   "planet_osm_nodes",
   "planet_osm_rels",
   "planet_osm_ways",
-  "raster_columns", 
-  "raster_overviews", 
+  "raster_columns",
+  "raster_overviews",
   "spatial_ref_sys" ].each do |table|
   postgresql_table table do
     cluster node[:tile][:database][:cluster]
@@ -366,10 +366,10 @@ end
   end
 end
 
-[ "geometry_columns", 
-  "planet_osm_line", 
-  "planet_osm_point", 
-  "planet_osm_polygon", 
+[ "geometry_columns",
+  "planet_osm_line",
+  "planet_osm_point",
+  "planet_osm_polygon",
   "planet_osm_roads" ].each do |table|
   postgresql_table table do
     cluster node[:tile][:database][:cluster]
@@ -513,7 +513,7 @@ template "/usr/local/bin/cleanup-tiles" do
   mode 0755
 end
 
-tile_directories = node[:tile][:styles].collect do |name,style|
+tile_directories = node[:tile][:styles].collect do |_, style|
   style[:tile_directories].collect { |directory| directory[:name] }
 end.flatten.sort.uniq