From 741593ee2bf203c9261f604d094e3d8e621698a8 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Sun, 5 Jan 2020 20:46:12 +0000 Subject: [PATCH] Fix new cookstyle warnings --- cookbooks/apache/resources/conf.rb | 2 +- cookbooks/apache/resources/module.rb | 2 +- cookbooks/apache/resources/site.rb | 2 +- cookbooks/blogs/recipes/default.rb | 4 ++-- cookbooks/fail2ban/resources/filter.rb | 2 +- cookbooks/fail2ban/resources/jail.rb | 2 +- cookbooks/imagery/recipes/default.rb | 4 ++-- cookbooks/imagery/resources/layer.rb | 6 +++--- cookbooks/kibana/recipes/default.rb | 4 ++-- cookbooks/mediawiki/resources/extension.rb | 2 +- cookbooks/mediawiki/resources/site.rb | 2 +- cookbooks/mediawiki/resources/skin.rb | 2 +- cookbooks/munin/resources/plugin.rb | 2 +- cookbooks/munin/resources/plugin_conf.rb | 2 +- cookbooks/mysql/resources/database.rb | 2 +- cookbooks/mysql/resources/user.rb | 2 +- cookbooks/nfs/recipes/default.rb | 2 +- cookbooks/nginx/resources/site.rb | 2 +- cookbooks/nodejs/resources/package.rb | 2 +- cookbooks/ohai/resources/plugin.rb | 2 +- cookbooks/otrs/recipes/default.rb | 6 +++--- cookbooks/passenger/resources/application.rb | 2 +- cookbooks/piwik/recipes/default.rb | 6 +++--- cookbooks/postgresql/resources/database.rb | 2 +- cookbooks/postgresql/resources/execute.rb | 2 +- cookbooks/postgresql/resources/extension.rb | 2 +- cookbooks/postgresql/resources/munin.rb | 2 +- cookbooks/postgresql/resources/table.rb | 2 +- cookbooks/postgresql/resources/tablespace.rb | 2 +- cookbooks/postgresql/resources/user.rb | 2 +- cookbooks/squid/resources/fragment.rb | 2 +- cookbooks/systemd/resources/path.rb | 2 +- cookbooks/systemd/resources/service.rb | 8 ++++---- cookbooks/systemd/resources/timer.rb | 6 +++--- cookbooks/tilelog/recipes/default.rb | 6 +++--- cookbooks/trac/recipes/default.rb | 2 +- cookbooks/web/resources/rails_port.rb | 8 ++++---- cookbooks/wordpress/resources/plugin.rb | 2 +- cookbooks/wordpress/resources/site.rb | 2 +- cookbooks/wordpress/resources/theme.rb | 2 +- 40 files changed, 59 insertions(+), 59 deletions(-) diff --git a/cookbooks/apache/resources/conf.rb b/cookbooks/apache/resources/conf.rb index 0ac19b0c7..5bedbab44 100644 --- a/cookbooks/apache/resources/conf.rb +++ b/cookbooks/apache/resources/conf.rb @@ -19,7 +19,7 @@ default_action [:create, :enable] -property :conf, :kind_of => String, :name_attribute => true +property :conf, :kind_of => String, :name_property => true property :cookbook, :kind_of => String property :template, :kind_of => String, :required => true property :variables, :kind_of => Hash, :default => {} diff --git a/cookbooks/apache/resources/module.rb b/cookbooks/apache/resources/module.rb index 0ac0f8f01..52cde2f85 100644 --- a/cookbooks/apache/resources/module.rb +++ b/cookbooks/apache/resources/module.rb @@ -19,7 +19,7 @@ default_action [:install, :enable] -property :module, :kind_of => String, :name_attribute => true +property :module, :kind_of => String, :name_property => true property :package, :kind_of => String property :conf, :kind_of => String property :variables, :kind_of => Hash, :default => {} diff --git a/cookbooks/apache/resources/site.rb b/cookbooks/apache/resources/site.rb index 5b5230425..f1016927c 100644 --- a/cookbooks/apache/resources/site.rb +++ b/cookbooks/apache/resources/site.rb @@ -19,7 +19,7 @@ default_action [:create, :enable] -property :site, :kind_of => String, :name_attribute => true +property :site, :kind_of => String, :name_property => true property :directory, :kind_of => String property :cookbook, :kind_of => String property :template, :kind_of => String, :required => true diff --git a/cookbooks/blogs/recipes/default.rb b/cookbooks/blogs/recipes/default.rb index d08fc482c..3f9a8ca25 100644 --- a/cookbooks/blogs/recipes/default.rb +++ b/cookbooks/blogs/recipes/default.rb @@ -41,7 +41,7 @@ git "/srv/blogs.openstreetmap.org" do repository "git://github.com/gravitystorm/blogs.osm.org.git" user "blogs" group "blogs" - notifies :run, "execute[/srv/blogs.openstreetmap.org/Gemfile]", :immediate + notifies :run, "execute[/srv/blogs.openstreetmap.org/Gemfile]", :immediately end execute "/srv/blogs.openstreetmap.org/Gemfile" do @@ -50,7 +50,7 @@ execute "/srv/blogs.openstreetmap.org/Gemfile" do cwd "/srv/blogs.openstreetmap.org" user "root" group "root" - notifies :run, "execute[/srv/blogs.openstreetmap.org]", :immediate + notifies :run, "execute[/srv/blogs.openstreetmap.org]", :immediately end execute "/srv/blogs.openstreetmap.org" do diff --git a/cookbooks/fail2ban/resources/filter.rb b/cookbooks/fail2ban/resources/filter.rb index d37ba4bb2..5e10241a4 100644 --- a/cookbooks/fail2ban/resources/filter.rb +++ b/cookbooks/fail2ban/resources/filter.rb @@ -19,7 +19,7 @@ default_action :create -property :filter, :kind_of => String, :name_attribute => true +property :filter, :kind_of => String, :name_property => true property :source, :kind_of => String property :failregex, :kind_of => [String, Array] property :ignoreregex, :kind_of => [String, Array] diff --git a/cookbooks/fail2ban/resources/jail.rb b/cookbooks/fail2ban/resources/jail.rb index c07914d2c..66fa19d2d 100644 --- a/cookbooks/fail2ban/resources/jail.rb +++ b/cookbooks/fail2ban/resources/jail.rb @@ -19,7 +19,7 @@ default_action :create -property :jail, :kind_of => String, :name_attribute => true +property :jail, :kind_of => String, :name_property => true property :filter, :kind_of => String property :logpath, :kind_of => String property :protocol, :kind_of => String diff --git a/cookbooks/imagery/recipes/default.rb b/cookbooks/imagery/recipes/default.rb index 13a7f915b..03d3fcc66 100644 --- a/cookbooks/imagery/recipes/default.rb +++ b/cookbooks/imagery/recipes/default.rb @@ -70,7 +70,7 @@ end remote_file "#{Chef::Config[:file_cache_path]}/ostn02-ntv2-data.zip" do source "https://www.ordnancesurvey.co.uk/docs/gps/ostn02-ntv2-data.zip" - not_if { File.exist?("/srv/imagery/common/ostn02-ntv2-data/OSTN02_NTv2.gsb") } + not_if { ::File.exist?("/srv/imagery/common/ostn02-ntv2-data/OSTN02_NTv2.gsb") } end execute "unzip-ostn02-ntv2-data" do @@ -78,7 +78,7 @@ execute "unzip-ostn02-ntv2-data" do cwd "/srv/imagery/common/ostn02-ntv2-data" user "root" group "root" - not_if { File.exist?("/srv/imagery/common/ostn02-ntv2-data/OSTN02_NTv2.gsb") } + not_if { ::File.exist?("/srv/imagery/common/ostn02-ntv2-data/OSTN02_NTv2.gsb") } end nginx_site "default" do diff --git a/cookbooks/imagery/resources/layer.rb b/cookbooks/imagery/resources/layer.rb index cddd95847..f8d3b1aa1 100644 --- a/cookbooks/imagery/resources/layer.rb +++ b/cookbooks/imagery/resources/layer.rb @@ -24,7 +24,7 @@ default_action :create property :layer, String, :name_property => true property :site, String, :required => true property :source, String, :required => true -property :root_layer, [TrueClass, FalseClass], :default => false +property :root_layer, [true, false], :default => false property :title, String property :copyright, String, :default => "Copyright" property :projection, String, :default => "EPSG:3857" @@ -37,8 +37,8 @@ property :extension, String, :default => "png" property :max_zoom, Integer, :default => 18 property :url_aliases, [String, Array], :default => [] property :revision, Integer, :default => 0 -property :overlay, [TrueClass, FalseClass], :default => false -property :default_layer, [TrueClass, FalseClass], :default => false +property :overlay, [true, false], :default => false +property :default_layer, [true, false], :default => false action :create do file "/srv/imagery/layers/#{new_resource.site}/#{new_resource.layer}.yml" do diff --git a/cookbooks/kibana/recipes/default.rb b/cookbooks/kibana/recipes/default.rb index c2e2693b3..8f20eb523 100644 --- a/cookbooks/kibana/recipes/default.rb +++ b/cookbooks/kibana/recipes/default.rb @@ -27,7 +27,7 @@ version = node[:kibana][:version] remote_file "#{Chef::Config[:file_cache_path]}/kibana-#{version}.tar.gz" do source "https://download.elastic.co/kibana/kibana/kibana-4.1.1-linux-x64.tar.gz" - not_if { File.exist?("/opt/kibana-#{version}/bin/kibana") } + not_if { ::File.exist?("/opt/kibana-#{version}/bin/kibana") } end directory "/opt/kibana-#{version}" do @@ -41,7 +41,7 @@ execute "unzip-kibana-#{version}" do cwd "/opt/kibana-#{version}" user "root" group "root" - not_if { File.exist?("/opt/kibana-#{version}/bin/kibana") } + not_if { ::File.exist?("/opt/kibana-#{version}/bin/kibana") } end directory "/etc/kibana" do diff --git a/cookbooks/mediawiki/resources/extension.rb b/cookbooks/mediawiki/resources/extension.rb index 1fe4faea5..95c7dff22 100644 --- a/cookbooks/mediawiki/resources/extension.rb +++ b/cookbooks/mediawiki/resources/extension.rb @@ -19,7 +19,7 @@ default_action :create -property :extension, :kind_of => String, :name_attribute => true +property :extension, :kind_of => String, :name_property => true property :site, :kind_of => String, :required => true property :source, :kind_of => String property :template, :kind_of => String diff --git a/cookbooks/mediawiki/resources/site.rb b/cookbooks/mediawiki/resources/site.rb index a3862ca52..55228af06 100644 --- a/cookbooks/mediawiki/resources/site.rb +++ b/cookbooks/mediawiki/resources/site.rb @@ -19,7 +19,7 @@ default_action :create -property :site, :kind_of => String, :name_attribute => true +property :site, :kind_of => String, :name_property => true property :aliases, :kind_of => [String, Array] property :directory, :kind_of => String property :version, :kind_of => String, :default => "1.33" diff --git a/cookbooks/mediawiki/resources/skin.rb b/cookbooks/mediawiki/resources/skin.rb index adcc2ae87..e9ac65145 100644 --- a/cookbooks/mediawiki/resources/skin.rb +++ b/cookbooks/mediawiki/resources/skin.rb @@ -19,7 +19,7 @@ default_action :create -property :skin, :kind_of => String, :name_attribute => true +property :skin, :kind_of => String, :name_property => true property :site, :kind_of => String, :required => true property :source, :kind_of => String property :template, :kind_of => String diff --git a/cookbooks/munin/resources/plugin.rb b/cookbooks/munin/resources/plugin.rb index dede3cb53..e9387b1e7 100644 --- a/cookbooks/munin/resources/plugin.rb +++ b/cookbooks/munin/resources/plugin.rb @@ -19,7 +19,7 @@ default_action :create -property :plugin, :kind_of => String, :name_attribute => true +property :plugin, :kind_of => String, :name_property => true property :target, :kind_of => String property :conf, :kind_of => String property :conf_cookbook, :kind_of => String diff --git a/cookbooks/munin/resources/plugin_conf.rb b/cookbooks/munin/resources/plugin_conf.rb index 1355052d7..ab9a54a65 100644 --- a/cookbooks/munin/resources/plugin_conf.rb +++ b/cookbooks/munin/resources/plugin_conf.rb @@ -19,7 +19,7 @@ default_action :create -property :plugin_conf, :kind_of => String, :name_attribute => true +property :plugin_conf, :kind_of => String, :name_property => true property :cookbook, :kind_of => [String, nil] property :template, :kind_of => String, :required => true property :variables, :kind_of => Hash, :default => {} diff --git a/cookbooks/mysql/resources/database.rb b/cookbooks/mysql/resources/database.rb index be985f563..65b6d2e22 100644 --- a/cookbooks/mysql/resources/database.rb +++ b/cookbooks/mysql/resources/database.rb @@ -19,7 +19,7 @@ default_action :create -property :database, :kind_of => String, :name_attribute => true +property :database, :kind_of => String, :name_property => true property :permissions, :kind_of => Hash, :default => {} action :create do diff --git a/cookbooks/mysql/resources/user.rb b/cookbooks/mysql/resources/user.rb index 13e344966..078316fc8 100644 --- a/cookbooks/mysql/resources/user.rb +++ b/cookbooks/mysql/resources/user.rb @@ -19,7 +19,7 @@ default_action :create -property :user, :kind_of => String, :name_attribute => true +property :user, :kind_of => String, :name_property => true property :password, :kind_of => String OpenStreetMap::MySQL::USER_PRIVILEGES.each do |privilege| diff --git a/cookbooks/nfs/recipes/default.rb b/cookbooks/nfs/recipes/default.rb index 80d3d9e21..c42cf9c82 100644 --- a/cookbooks/nfs/recipes/default.rb +++ b/cookbooks/nfs/recipes/default.rb @@ -31,7 +31,7 @@ node[:nfs].each do |mountpoint, details| group "root" mode 0o755 recursive true - not_if { File.exist?(mountpoint) } + not_if { ::File.exist?(mountpoint) } end mount mountpoint do diff --git a/cookbooks/nginx/resources/site.rb b/cookbooks/nginx/resources/site.rb index 5ebaca69b..3c47d3091 100644 --- a/cookbooks/nginx/resources/site.rb +++ b/cookbooks/nginx/resources/site.rb @@ -19,7 +19,7 @@ default_action :create -property :site, :kind_of => String, :name_attribute => true +property :site, :kind_of => String, :name_property => true property :directory, :kind_of => String property :cookbook, :kind_of => String property :template, :kind_of => String, :required => true diff --git a/cookbooks/nodejs/resources/package.rb b/cookbooks/nodejs/resources/package.rb index 9d30c164f..b5024147a 100644 --- a/cookbooks/nodejs/resources/package.rb +++ b/cookbooks/nodejs/resources/package.rb @@ -21,7 +21,7 @@ require "json" default_action :install -property :package, :kind_of => String, :name_attribute => true +property :package, :kind_of => String, :name_property => true property :version, :kind_of => String action :install do diff --git a/cookbooks/ohai/resources/plugin.rb b/cookbooks/ohai/resources/plugin.rb index 54e401082..9367a4d83 100644 --- a/cookbooks/ohai/resources/plugin.rb +++ b/cookbooks/ohai/resources/plugin.rb @@ -19,7 +19,7 @@ default_action :create -property :plugin, :kind_of => String, :name_attribute => true +property :plugin, :kind_of => String, :name_property => true property :template, :kind_of => String, :required => true action :create do diff --git a/cookbooks/otrs/recipes/default.rb b/cookbooks/otrs/recipes/default.rb index b5225e289..b1a5a0107 100644 --- a/cookbooks/otrs/recipes/default.rb +++ b/cookbooks/otrs/recipes/default.rb @@ -61,7 +61,7 @@ end remote_file "#{Chef::Config[:file_cache_path]}/otrs-#{version}.tar.bz2" do source "https://ftp.otrs.org/pub/otrs/otrs-#{version}.tar.bz2" - not_if { File.exist?("/opt/otrs-#{version}") } + not_if { ::File.exist?("/opt/otrs-#{version}") } end execute "untar-otrs-#{version}" do @@ -69,7 +69,7 @@ execute "untar-otrs-#{version}" do cwd "/opt" user "root" group "root" - not_if { File.exist?("/opt/otrs-#{version}") } + not_if { ::File.exist?("/opt/otrs-#{version}") } end config = edit_file "/opt/otrs-#{version}/Kernel/Config.pm.dist" do |line| @@ -109,7 +109,7 @@ execute "/opt/otrs/bin/otrs.RebuildConfig.pl" do command "/opt/otrs/bin/otrs.RebuildConfig.pl" user "root" group "root" - not_if { File.exist?("/opt/otrs/Kernel/Config/Files/ZZZAAuto.pm") } + not_if { ::File.exist?("/opt/otrs/Kernel/Config/Files/ZZZAAuto.pm") } end execute "/opt/otrs/bin/Cron.sh" do diff --git a/cookbooks/passenger/resources/application.rb b/cookbooks/passenger/resources/application.rb index f2af9a2e8..3eef14c7f 100644 --- a/cookbooks/passenger/resources/application.rb +++ b/cookbooks/passenger/resources/application.rb @@ -19,7 +19,7 @@ default_action :restart -property :application, String, :name_attribute => true +property :application, String, :name_property => true action :restart do execute new_resource.application do diff --git a/cookbooks/piwik/recipes/default.rb b/cookbooks/piwik/recipes/default.rb index 459712a0e..a6b2bf3a7 100644 --- a/cookbooks/piwik/recipes/default.rb +++ b/cookbooks/piwik/recipes/default.rb @@ -46,7 +46,7 @@ end remote_file "#{Chef::Config[:file_cache_path]}/piwik-#{version}.zip" do source "https://builds.matomo.org/piwik-#{version}.zip" - not_if { File.exist?("/opt/piwik-#{version}/piwik") } + not_if { ::File.exist?("/opt/piwik-#{version}/piwik") } end execute "unzip-piwik-#{version}" do @@ -54,7 +54,7 @@ execute "unzip-piwik-#{version}" do cwd "/opt/piwik-#{version}" user "root" group "root" - not_if { File.exist?("/opt/piwik-#{version}/piwik") } + not_if { ::File.exist?("/opt/piwik-#{version}/piwik") } end execute "/opt/piwik-#{version}/piwik/piwik.js" do @@ -62,7 +62,7 @@ execute "/opt/piwik-#{version}/piwik/piwik.js" do cwd "/opt/piwik-#{version}" user "root" group "root" - not_if { File.exist?("/opt/piwik-#{version}/piwik/piwik.js.gz") } + not_if { ::File.exist?("/opt/piwik-#{version}/piwik/piwik.js.gz") } end directory "/opt/piwik-#{version}/piwik/config" do diff --git a/cookbooks/postgresql/resources/database.rb b/cookbooks/postgresql/resources/database.rb index 9cc4f1e0e..c0e7e0de4 100644 --- a/cookbooks/postgresql/resources/database.rb +++ b/cookbooks/postgresql/resources/database.rb @@ -19,7 +19,7 @@ default_action :create -property :database, :kind_of => String, :name_attribute => true +property :database, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :owner, :kind_of => String, :required => true property :encoding, :kind_of => String, :default => "UTF8" diff --git a/cookbooks/postgresql/resources/execute.rb b/cookbooks/postgresql/resources/execute.rb index 463a80edb..7a0f5b7b9 100644 --- a/cookbooks/postgresql/resources/execute.rb +++ b/cookbooks/postgresql/resources/execute.rb @@ -19,7 +19,7 @@ default_action :run -property :command, :kind_of => String, :name_attribute => true +property :command, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :database, :kind_of => String, :required => true property :user, :default => "postgres" diff --git a/cookbooks/postgresql/resources/extension.rb b/cookbooks/postgresql/resources/extension.rb index 24df6c568..3adcfd62b 100644 --- a/cookbooks/postgresql/resources/extension.rb +++ b/cookbooks/postgresql/resources/extension.rb @@ -19,7 +19,7 @@ default_action :create -property :extension, :kind_of => String, :name_attribute => true +property :extension, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :database, :kind_of => String, :required => true diff --git a/cookbooks/postgresql/resources/munin.rb b/cookbooks/postgresql/resources/munin.rb index e069a8772..311325b0f 100644 --- a/cookbooks/postgresql/resources/munin.rb +++ b/cookbooks/postgresql/resources/munin.rb @@ -19,7 +19,7 @@ default_action :create -property :munin, :kind_of => String, :name_attribute => true +property :munin, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :database, :kind_of => String, :required => true diff --git a/cookbooks/postgresql/resources/table.rb b/cookbooks/postgresql/resources/table.rb index 75df2f60c..4bb2431ee 100644 --- a/cookbooks/postgresql/resources/table.rb +++ b/cookbooks/postgresql/resources/table.rb @@ -19,7 +19,7 @@ default_action :create -property :table, :kind_of => String, :name_attribute => true +property :table, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :database, :kind_of => String, :required => true property :schema, :kind_of => String, :default => "public" diff --git a/cookbooks/postgresql/resources/tablespace.rb b/cookbooks/postgresql/resources/tablespace.rb index 0fa05cafc..82e901228 100644 --- a/cookbooks/postgresql/resources/tablespace.rb +++ b/cookbooks/postgresql/resources/tablespace.rb @@ -19,7 +19,7 @@ default_action :create -property :tablespace, :kind_of => String, :name_attribute => true +property :tablespace, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :location, :kind_of => String, :required => true diff --git a/cookbooks/postgresql/resources/user.rb b/cookbooks/postgresql/resources/user.rb index 072b18424..2fac86731 100644 --- a/cookbooks/postgresql/resources/user.rb +++ b/cookbooks/postgresql/resources/user.rb @@ -21,7 +21,7 @@ require "shellwords" default_action :create -property :user, :kind_of => String, :name_attribute => true +property :user, :kind_of => String, :name_property => true property :cluster, :kind_of => String, :required => true property :password, :kind_of => String property :superuser, :default => false diff --git a/cookbooks/squid/resources/fragment.rb b/cookbooks/squid/resources/fragment.rb index d3778c4ac..152a6d971 100644 --- a/cookbooks/squid/resources/fragment.rb +++ b/cookbooks/squid/resources/fragment.rb @@ -19,7 +19,7 @@ default_action :create -property :fragment, :kind_of => String, :name_attribute => true +property :fragment, :kind_of => String, :name_property => true property :template, :kind_of => String, :required => true property :variables, :kind_of => Hash, :default => {} diff --git a/cookbooks/systemd/resources/path.rb b/cookbooks/systemd/resources/path.rb index 139f4b8db..448a47cd6 100644 --- a/cookbooks/systemd/resources/path.rb +++ b/cookbooks/systemd/resources/path.rb @@ -29,7 +29,7 @@ property :path_changed, [String, Array] property :path_modified, [String, Array] property :directory_not_empty, [String, Array] property :unit, String -property :make_directory, [TrueClass, FalseClass] +property :make_directory, [true, false] property :directory_mode, Integer action :create do diff --git a/cookbooks/systemd/resources/service.rb b/cookbooks/systemd/resources/service.rb index dfb6864c5..8098d51da 100644 --- a/cookbooks/systemd/resources/service.rb +++ b/cookbooks/systemd/resources/service.rb @@ -52,13 +52,13 @@ property :standard_error, String, property :success_exit_status, [Integer, String, Array] property :restart, String, :is => %w[on-success on-failure on-abnormal on-watchdog on-abort always] -property :private_tmp, [TrueClass, FalseClass] -property :private_devices, [TrueClass, FalseClass] -property :private_network, [TrueClass, FalseClass] +property :private_tmp, [true, false] +property :private_devices, [true, false] +property :private_network, [true, false] property :protect_system, [TrueClass, FalseClass, String] property :protect_home, [TrueClass, FalseClass, String] property :restrict_address_families, [String, Array] -property :no_new_privileges, [TrueClass, FalseClass] +property :no_new_privileges, [true, false] property :tasks_max, Integer property :timeout_sec, Integer property :pid_file, String diff --git a/cookbooks/systemd/resources/timer.rb b/cookbooks/systemd/resources/timer.rb index b33cff2d0..91de6e909 100644 --- a/cookbooks/systemd/resources/timer.rb +++ b/cookbooks/systemd/resources/timer.rb @@ -32,9 +32,9 @@ property :on_calendar, String property :accuracy_sec, [Integer, String] property :randomized_delay_sec, [Integer, String] property :unit, String -property :persistent, [TrueClass, FalseClass] -property :wake_system, [TrueClass, FalseClass] -property :remain_after_elapse, [TrueClass, FalseClass] +property :persistent, [true, false] +property :wake_system, [true, false] +property :remain_after_elapse, [true, false] action :create do timer_variables = new_resource.to_hash diff --git a/cookbooks/tilelog/recipes/default.rb b/cookbooks/tilelog/recipes/default.rb index edc6e7e72..0eefa7c7c 100644 --- a/cookbooks/tilelog/recipes/default.rb +++ b/cookbooks/tilelog/recipes/default.rb @@ -40,7 +40,7 @@ git tilelog_source_directory do revision "live" user "root" group "root" - notifies :run, "execute[tilelog-autogen]", :immediate + notifies :run, "execute[tilelog-autogen]", :immediately end execute "tilelog-autogen" do @@ -49,7 +49,7 @@ execute "tilelog-autogen" do cwd tilelog_source_directory user "root" group "root" - notifies :run, "execute[tilelog-configure]", :immediate + notifies :run, "execute[tilelog-configure]", :immediately end execute "tilelog-configure" do @@ -58,7 +58,7 @@ execute "tilelog-configure" do cwd tilelog_source_directory user "root" group "root" - notifies :run, "execute[tilelog-build]", :immediate + notifies :run, "execute[tilelog-build]", :immediately end execute "tilelog-build" do diff --git a/cookbooks/trac/recipes/default.rb b/cookbooks/trac/recipes/default.rb index f7472131d..8c397db8a 100644 --- a/cookbooks/trac/recipes/default.rb +++ b/cookbooks/trac/recipes/default.rb @@ -62,7 +62,7 @@ execute "trac-deploy-#{site_name}" do command "trac-admin /var/lib/trac deploy #{site_directory}" user "root" group "root" - not_if { File.exist?(site_directory) } + not_if { ::File.exist?(site_directory) } end cookbook_file "/usr/local/bin/trac-authenticate" do diff --git a/cookbooks/web/resources/rails_port.rb b/cookbooks/web/resources/rails_port.rb index 19da5f5ba..79a969ee9 100644 --- a/cookbooks/web/resources/rails_port.rb +++ b/cookbooks/web/resources/rails_port.rb @@ -23,14 +23,14 @@ resource_name :rails_port default_action :create -property :site, String, :name_attribute => true +property :site, String, :name_property => true property :ruby, String, :default => "2.3" property :directory, String property :user, String property :group, String property :repository, String, :default => "https://git.openstreetmap.org/public/rails.git" property :revision, String, :default => "live" -property :run_migrations, [TrueClass, FalseClass], :default => false +property :run_migrations, [true, false], :default => false property :email_from, String, :default => "OpenStreetMap " property :status, String, :default => "online" property :database_host, String @@ -63,10 +63,10 @@ property :wikipedia_auth_id, String property :wikipedia_auth_secret, String property :thunderforest_key, String property :totp_key, String -property :csp_enforce, [TrueClass, FalseClass], :default => false +property :csp_enforce, [true, false], :default => false property :csp_report_url, String property :piwik_configuration, Hash -property :trace_use_job_queue, [TrueClass, FalseClass], :default => false +property :trace_use_job_queue, [true, false], :default => false property :diary_feed_delay, Integer property :storage_configuration, Hash, :default => {} property :storage_service, String, :default => "local" diff --git a/cookbooks/wordpress/resources/plugin.rb b/cookbooks/wordpress/resources/plugin.rb index 778ff6583..468440eca 100644 --- a/cookbooks/wordpress/resources/plugin.rb +++ b/cookbooks/wordpress/resources/plugin.rb @@ -19,7 +19,7 @@ default_action :create -property :plugin, :kind_of => String, :name_attribute => true +property :plugin, :kind_of => String, :name_property => true property :site, :kind_of => String, :required => true property :source, :kind_of => String property :version, :kind_of => String diff --git a/cookbooks/wordpress/resources/site.rb b/cookbooks/wordpress/resources/site.rb index 72af236b6..1f4e67cc0 100644 --- a/cookbooks/wordpress/resources/site.rb +++ b/cookbooks/wordpress/resources/site.rb @@ -20,7 +20,7 @@ require "securerandom" default_action :create -property :site, :kind_of => String, :name_attribute => true +property :site, :kind_of => String, :name_property => true property :aliases, :kind_of => [String, Array] property :directory, :kind_of => String property :version, :kind_of => String diff --git a/cookbooks/wordpress/resources/theme.rb b/cookbooks/wordpress/resources/theme.rb index d98edb25d..3547f0aae 100644 --- a/cookbooks/wordpress/resources/theme.rb +++ b/cookbooks/wordpress/resources/theme.rb @@ -19,7 +19,7 @@ default_action :create -property :theme, :kind_of => String, :name_attribute => true +property :theme, :kind_of => String, :name_property => true property :site, :kind_of => String, :required => true property :source, :kind_of => String property :version, :kind_of => String -- 2.43.2