Merge branch 'consul-reboot-check-fix' of kazu634/itamae into master
This commit is contained in:
commit
ffffb05627
|
@ -2,7 +2,7 @@
|
||||||
"check": {
|
"check": {
|
||||||
"id": "reboot-required",
|
"id": "reboot-required",
|
||||||
"name": "Check for Reboot Required",
|
"name": "Check for Reboot Required",
|
||||||
"args": ["/usr/lib/nagios/plugins/check_file", "/var/run/reboot-required"],
|
"args": ["/usr/local/bin/check_file", "/var/run/reboot-required"],
|
||||||
"interval": "86400s",
|
"interval": "86400s",
|
||||||
"timeout": "10s"
|
"timeout": "10s"
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,9 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
TARGET=$1
|
||||||
|
|
||||||
|
if [ -f ${TARGET} ]; then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
exit 0
|
|
@ -1,3 +1,9 @@
|
||||||
|
remote_file '/usr/local/bin/check_file' do
|
||||||
|
owner 'root'
|
||||||
|
group 'root'
|
||||||
|
mode '755'
|
||||||
|
end
|
||||||
|
|
||||||
%w(reboot-required).each do |conf|
|
%w(reboot-required).each do |conf|
|
||||||
remote_file "/etc/consul.d/check-#{conf}.json" do
|
remote_file "/etc/consul.d/check-#{conf}.json" do
|
||||||
owner 'root'
|
owner 'root'
|
||||||
|
|
Loading…
Reference in New Issue