summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryan McLellan <btm@opscode.com>2012-08-30 12:57:39 -0700
committerBryan McLellan <btm@opscode.com>2012-08-30 12:57:39 -0700
commit6f06f4d8a4f0c024f7af2eab85e60a5b1908e47c (patch)
tree8e4c7565f755c0af8caa931b814c3457fd0ef2f0
parent4fbf83348f25b47b766ae62d67a1b94bac90deb9 (diff)
downloadchef-6f06f4d8a4f0c024f7af2eab85e60a5b1908e47c.tar.gz
CHEF-3380: Don't fail redhat service on stop or disable if init script is missing
-rw-r--r--chef/lib/chef/provider/service/redhat.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/chef/lib/chef/provider/service/redhat.rb b/chef/lib/chef/provider/service/redhat.rb
index e62bc97e0d..629e4ee0c3 100644
--- a/chef/lib/chef/provider/service/redhat.rb
+++ b/chef/lib/chef/provider/service/redhat.rb
@@ -45,7 +45,7 @@ class Chef
a.failure_message Chef::Exceptions::Service, "#{chkconfig_file} does not exist!"
end
- requirements.assert(:all_actions) do |a|
+ requirements.assert(:start, :enable, :reload, :restart) do |a|
a.assertion { !@service_missing }
a.failure_message Chef::Exceptions::Service, "#{@new_resource}: unable to locate the init.d script!"
a.whyrun "Assuming service would be disabled. The init script is not presently installed."