Created
September 28, 2017 21:01
-
-
Save salekseev/334ecf479084c80b2d7685e268e9b997 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'diplomat' | |
service = 'mongodb' | |
puts Diplomat::Health.service(service, passing: true).map { |service| service['Service']['Address'] + ':' + service['Service']['Port'].to_s } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment