Skip to main content

PowershellInstallPackage

The department is: PowershellInstallPackage

The full name of the cop is: Chef/Modernize/PowershellInstallPackage

Enabled by defaultSupports autocorrectionTarget Chef Version
EnabledNo12.16+

Use the powershell_package resource built into Chef Infra Client instead of the powershell_script resource to run Install-Package

correct

powershell_package ‘docker’

Examples

incorrect

powershell_script 'Expand website' do
  code 'Install-Package -Name docker'
end

Configurable attributes

NameDefault valueConfigurable values
Version Added5.5.0String
Include
    Array

    Was this page helpful?

    ×









    Search Results