Update the mediawiki cookbook and upstream cookbooks
Compatibility with Chef 14
This commit is contained in:
@@ -26,12 +26,13 @@ property :destination, String, default: '/Applications'
|
||||
property :checksum, String
|
||||
property :volumes_dir, String
|
||||
property :dmg_name, String
|
||||
property :type, String, default: 'app'
|
||||
property :type, String, default: 'app', equal_to: %w(app pkg mpkg)
|
||||
property :installed, [true, false], default: false, desired_state: false
|
||||
property :package_id, String
|
||||
property :dmg_passphrase, String
|
||||
property :accept_eula, [true, false], default: false
|
||||
property :headers, [Hash, nil], default: nil
|
||||
property :allow_untrusted, [true, false], default: false
|
||||
|
||||
load_current_value do |new_resource|
|
||||
if ::File.directory?("#{new_resource.destination}/#{new_resource.app}.app")
|
||||
@@ -87,7 +88,10 @@ action :install do
|
||||
ignore_failure true
|
||||
end
|
||||
when 'mpkg', 'pkg'
|
||||
execute "installation_file=$(ls '/Volumes/#{volumes_dir}' | grep '.#{new_resource.type}$') && sudo installer -pkg \"/Volumes/#{volumes_dir}/$installation_file\" -target /" do
|
||||
install_cmd = "installation_file=$(ls '/Volumes/#{volumes_dir}' | grep '.#{new_resource.type}$') && sudo installer -pkg \"/Volumes/#{volumes_dir}/$installation_file\" -target /"
|
||||
install_cmd += ' -allowUntrusted' if new_resource.allow_untrusted
|
||||
|
||||
execute install_cmd do
|
||||
# Prevent cfprefsd from holding up hdiutil detach for certain disk images
|
||||
environment('__CFPREFERENCES_AVOID_DAEMON' => '1')
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user