Chef/Deprecations/DeprecatedSudoActions
The Cookstyle cops department: Chef/Deprecations
| Enabled by default | Supports autocorrection | Target Chef Version |
|---|---|---|
| Enabled | Yes | 14.0+ |
The sudo resource in the sudo cookbook 5.0 (2018) or Chef Infra Client 14 and later have replaced the existing :install and :remove actions with :create and :delete actions to better match other resources in Chef Infra.
Examples
incorrect
sudo 'admins' do
users 'bob'
groups 'sysadmins, superusers'
action :remove
end
correct
sudo 'admins' do
users 'bob'
groups 'sysadmins, superusers'
action :delete
end
Configurable attributes
| Name | Default value | Configurable values |
|---|---|---|
| Version Added | 7.18.0 | String |
| Include | Array |