Skip to content

Instantly share code, notes, and snippets.

@slb350
Last active August 29, 2015 14:27
Show Gist options
  • Save slb350/db97c193dd4b98d15fa2 to your computer and use it in GitHub Desktop.
Save slb350/db97c193dd4b98d15fa2 to your computer and use it in GitHub Desktop.
require 'pagerduty'
fbproc=`redis-cli -h {{ redis_host }} {{ monitored_queue }} `.to_i
puts fbproc
queue = case fbproc
when 0..10 then Pagerduty.new("{{ pager_duty_key }}")
when 11..100 then "Pass"
else "Burn it Down"
end
puts queue
~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment