Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Added support for IRC notifications #130

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants

aleks commented Apr 11, 2013

I added support for IRC Contacts / Notification.

God.watch do |w|
  God.contact(:irc) do |c|
    c.name = 'irc'
    c.host = 'irc.freenode.org'
    c.port = 6667
    c.channel = '#mychannel'
    c.nick = 'its_me_god'
    c.realname = "God"
  end

  w.name = "my_task"
  w.start = "ruby do_random_stuff.rb"
  w.keepalive(:memory_max => 150.megabytes, :cpu_max => 50.percent)
  w.interval = 60.seconds
  w.behavior(:clean_pid_file)

  w.transition(:up, :restart) do |on|
    on.condition(:process_exits) do |c|
      c.notify = 'irc'
    end
  end
end
Collaborator

eric commented Jun 3, 2013

Looks good.

Could you add a simple test like https://github.com/mojombo/god/blob/master/test/test_jabber.rb ?

@aleks aleks closed this Feb 4, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment