You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it's useful to see why puppet has been disbled right away, so I hacked a little patch. I'm not into ruby, so it's probably not the correct style, but it works:
@@ -28,6 +28,7 @@
$LOAD_PATH.unshift File.expand_path('/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/', __FILE__)
# end fix to make it run on jessie
+require "json"
require "optparse"
require "puppet"
require "puppet/defaults"
@@ -227,10 +228,13 @@
puts "checking puppet is enabled"
end
if FileTest.exist?("#{OPTIONS[:lockfile]}")
+ lfile = File.open("#{OPTIONS[:lockfile]}", 'r')
+ ldata = JSON.load lfile
+ lreason = ldata["disabled_message"]
# This used to be the case pre 2.6, not supporting that any more
# if File.zero?("#{OPTIONS[:lockfile]}")
@enabled_status = "CRITICAL"
- @enabled_msg = "PUPPET RUNS DISABLED"
+ @enabled_msg = "PUPPET RUNS DISABLED, reason: '#{lreason}'"
# else
# @enabled_status = "OK"
# @enabled_msg = "puppet runs enabled (currently in progress)"
The text was updated successfully, but these errors were encountered:
I think it's useful to see why puppet has been disbled right away, so I hacked a little patch. I'm not into ruby, so it's probably not the correct style, but it works:
The text was updated successfully, but these errors were encountered: