Guest User

Untitled

a guest
Dec 12th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1.  
  2. couchbase_hosts = Array.new
  3.  
  4. # Populate couchbase_hosts Array via RightLink tag.
  5.  
  6. results = rightscale_server_collection "couchbase_hosts" do
  7. tags ["couchbase:rs_main_cb=*"]
  8. secondary_tags ["server:public_ip_0=*"]
  9. action :nothing
  10. end
  11.  
  12. if node["server_collection"]["couchbase_hosts"]
  13. node["server_collection"]["couchbase_hosts"].to_hash.values.each do |tags|
  14. couchbase_hosts.push(RightScale::Utils::Helper.get_tag_value("server:public_ip_0", tags))
  15. end
  16. else
  17. log " ERROR: Install couchbase first before running this recipe."
  18. end
Add Comment
Please, Sign In to add comment