]> git.openstreetmap.org Git - chef.git/commitdiff
Make sure old APIs are cleaned up on dev
authorTom Hughes <tom@compton.nu>
Wed, 9 Mar 2022 19:21:51 +0000 (19:21 +0000)
committerTom Hughes <tom@compton.nu>
Wed, 9 Mar 2022 19:21:51 +0000 (19:21 +0000)
cookbooks/dev/recipes/default.rb

index 5a4110c7513cd2dffa8261003d2346c611f72049..d7d88656a688ca6b995ad7d1d0a5e7d4f4b6f14b 100644 (file)
@@ -248,6 +248,10 @@ if node[:postgresql][:clusters][:"14/main"]
 
   cgimap_port = 9000
 
 
   cgimap_port = 9000
 
+  Dir.glob("/srv/*.apis.dev.openstreetmap.org").each do |dir|
+    node.default_unless[:dev][:rails][File.basename(dir).split(".").first] = {}
+  end
+
   node[:dev][:rails].each do |name, details|
     database_name = details[:database] || "apis_#{name}"
     site_name = "#{name}.apis.dev.openstreetmap.org"
   node[:dev][:rails].each do |name, details|
     database_name = details[:database] || "apis_#{name}"
     site_name = "#{name}.apis.dev.openstreetmap.org"