Skip to content

Instantly share code, notes, and snippets.

@matschaffer
Created February 26, 2013 14:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save matschaffer/5038732 to your computer and use it in GitHub Desktop.
Save matschaffer/5038732 to your computer and use it in GitHub Desktop.
def subscribe_to_switch_master
redis.subscribe('+switch-master') do |on|
on.message do |channel, message|
reconfigure
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment