]> git.openstreetmap.org Git - chef.git/commitdiff
Fix new cookstyle warnings
authorTom Hughes <tom@compton.nu>
Thu, 26 Aug 2021 11:21:33 +0000 (12:21 +0100)
committerTom Hughes <tom@compton.nu>
Thu, 26 Aug 2021 11:21:33 +0000 (12:21 +0100)
cookbooks/blog/recipes/default.rb
cookbooks/civicrm/recipes/default.rb
cookbooks/dev/recipes/default.rb
cookbooks/docker/recipes/default.rb
cookbooks/hardware/recipes/default.rb
cookbooks/letsencrypt/recipes/default.rb
cookbooks/networking/recipes/default.rb
cookbooks/planet/recipes/current.rb
cookbooks/stateofthemap/recipes/default.rb

index 1f292eeb1dfd76b2e008f432b9da2259753ede0a..e746b1006526aaea149cfbbe3dd18109fd80a124 100644 (file)
@@ -66,7 +66,7 @@ wordpress_plugin "blog.openstreetmap.org-sitepress-multilingual-cms" do
   plugin "sitepress-multilingual-cms"
   site "blog.openstreetmap.org"
   repository "https://git.openstreetmap.org/private/sitepress-multilingual-cms.git"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 wordpress_plugin "blog.openstreetmap.org-wordpress-importer" do
index a8881fc0d898773faf33a35af7216a4e5eab2ed5..ced22c5f43814c0b2be5b326e2aa5bc6ac68af12 100644 (file)
@@ -64,7 +64,7 @@ end
 wordpress_plugin "sitepress-multilingual-cms" do
   site "join.osmfoundation.org"
   repository "https://git.openstreetmap.org/private/sitepress-multilingual-cms.git"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 wordpress_plugin "contact-form-7" do
index 15e9e7bbf6f1d986d5eb9070dfd5a30053846763..e0366f69ecda6f591f18bfe92a76838e1c2e745c 100644 (file)
@@ -352,7 +352,7 @@ if node[:postgresql][:clusters][:"13/main"]
           cwd cgimap_directory
           user "apis"
           group "apis"
-          subscribes :run, "git[#{cgimap_directory}]", :immediate
+          subscribes :run, "git[#{cgimap_directory}]", :immediately
         end
 
         execute "#{cgimap_directory}/configure" do
@@ -361,7 +361,7 @@ if node[:postgresql][:clusters][:"13/main"]
           cwd cgimap_directory
           user "apis"
           group "apis"
-          subscribes :run, "execute[#{cgimap_directory}/autogen.sh]", :immediate
+          subscribes :run, "execute[#{cgimap_directory}/autogen.sh]", :immediately
         end
 
         execute "#{cgimap_directory}/Makefile" do
@@ -370,7 +370,7 @@ if node[:postgresql][:clusters][:"13/main"]
           cwd cgimap_directory
           user "apis"
           group "apis"
-          subscribes :run, "execute[#{cgimap_directory}/configure]", :immediate
+          subscribes :run, "execute[#{cgimap_directory}/configure]", :immediately
           notifies :restart, "service[cgimap@#{name}]"
         end
 
index 23891f110c3e59c82fb960b995e7e8667cf9f7fc..80fd15b3f6be34ac90b8a3776f50df9d1f984b2b 100644 (file)
@@ -41,5 +41,5 @@ end
 service "docker" do
   action [:enable, :start]
   subscribes :restart, "template[/etc/docker/daemon.json]"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
index 957121785b2de1db9123b4ed921548d4d4c810ea..14e416d1d044718fc39d89f2a2f9467513237e2a 100644 (file)
@@ -141,7 +141,7 @@ if File.exist?("/etc/default/grub")
   execute "update-grub" do
     action :nothing
     command "/usr/sbin/update-grub"
-    not_if { ENV["TEST_KITCHEN"] }
+    not_if { kitchen? }
   end
 
   template "/etc/default/grub" do
@@ -274,7 +274,7 @@ if tools_packages.include?("areca")
     depth 1
     user "root"
     group "root"
-    not_if { ENV["TEST_KITCHEN"] }
+    not_if { kitchen? }
   end
 else
   directory "/opt/areca" do
index c41732cf64bf28db7815c6a16b1cee68703aa325..a327119bf195974a2764a22490e9219111ace6e3 100644 (file)
@@ -148,7 +148,7 @@ certificates.each do |name, details|
     user "letsencrypt"
     group "letsencrypt"
     subscribes :run, "template[/srv/acme.openstreetmap.org/requests/#{name}]"
-    not_if { ENV["TEST_KITCHEN"] }
+    not_if { kitchen? }
   end
 end
 
index c76d47e3e120bf91b4478b5f7e8d909dfeddf012..7bbf315057f5a67c2ad04ae85b1153a7ad655400 100644 (file)
@@ -321,7 +321,7 @@ template "/etc/hosts" do
   owner "root"
   group "root"
   mode "644"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 service "systemd-resolved" do
index 9f951df53137a6fda61d5b02c63129800ed28cc7..c7175e6e17ebd0b55597b55a2d33f93ce1c79176 100644 (file)
@@ -49,7 +49,7 @@ remote_file "/var/lib/planet/planet.osh.pbf" do
   owner "planet"
   group "planet"
   mode "644"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 cron_d "planet-update" do
index b2a40d1e74087a73632e3988bb1e0ad208ebb9f2..34766a11a9f100cc411b4755961e9d582ea8245c 100644 (file)
@@ -173,7 +173,7 @@ wordpress_plugin "2010.stateofthemap.org-sitepress-multilingual-cms" do
   plugin "sitepress-multilingual-cms"
   site "2010.stateofthemap.org"
   repository "https://git.openstreetmap.org/private/sitepress-multilingual-cms.git"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 wordpress_plugin "2010.stateofthemap.org-wp-sticky" do
@@ -217,7 +217,7 @@ wordpress_plugin "2011.stateofthemap.org-sitepress-multilingual-cms" do
   plugin "sitepress-multilingual-cms"
   site "2011.stateofthemap.org"
   repository "https://git.openstreetmap.org/private/sitepress-multilingual-cms.git"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 wordpress_plugin "2011.stateofthemap.org-wp-sticky" do
@@ -266,7 +266,7 @@ wordpress_plugin "2012.stateofthemap.org-sitepress-multilingual-cms" do
   plugin "sitepress-multilingual-cms"
   site "2012.stateofthemap.org"
   repository "https://git.openstreetmap.org/private/sitepress-multilingual-cms.git"
-  not_if { ENV["TEST_KITCHEN"] }
+  not_if { kitchen? }
 end
 
 wordpress_plugin "2012.stateofthemap.org-wp-sticky" do