Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

[FIX] Prevent Monit template failures on non-standard Monit books

The https://github.com/phlipper/chef-monit cookbook does not define
the `monitrc` method, but uses the `monit_monitrc` LWRP.

See phlipper/chef-monit@2802d12
  • Loading branch information...
commit a774cb347ddcd237237a41085add77c678110f05 1 parent a3fc3d7
@karmi karmi authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  recipes/nginx.rb
View
2  recipes/nginx.rb
@@ -41,7 +41,7 @@
notifies :restart, 'service[nginx]', :immediately
end
-if node.recipes.include?('monit') and defined?(:monitrc)
+if node.recipes.include?('monit') and respond_to?(:monitrc)
monitrc "nginx.monitrc" do
template_cookbook 'elasticsearch'
source 'nginx.monitrc.conf.erb'
Please sign in to comment.
Something went wrong with that request. Please try again.