diff options
author | Tim Smith <tsmith@chef.io> | 2018-04-26 16:26:20 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2018-04-26 16:26:20 -0700 |
commit | ed82d81fb3d1aac8c20fe6ea6101834f39366f19 (patch) | |
tree | 0d9100302c41b2b49b3bf3dc59ce1298f3ca7ace | |
parent | 7163130cb1209a9565d6137f3e3e6f1eacc94e0f (diff) | |
download | chef-ed82d81fb3d1aac8c20fe6ea6101834f39366f19.tar.gz |
sysctl: Fix ignore_error being ignoredsysctl_fix
This came into the sysctl cookbook https://github.com/sous-chefs/sysctl/pull/127
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | lib/chef/resource/sysctl.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/chef/resource/sysctl.rb b/lib/chef/resource/sysctl.rb index bf6864db31..75d2ef3262 100644 --- a/lib/chef/resource/sysctl.rb +++ b/lib/chef/resource/sysctl.rb @@ -84,7 +84,10 @@ class Chef content "#{new_resource.key} = #{new_resource.value}" end - execute "sysctl -p" + execute "sysctl -p" do + command "sysctl #{'-e ' if new_resource.ignore_error}-p" + action :run + end end end |