{"action":"closed","number":29,"pull_request":{"url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29","id":72244244,"html_url":"https://github.com/AnsibleShipyard/ansible-zookeeper/pull/29","diff_url":"https://github.com/AnsibleShipyard/ansible-zookeeper/pull/29.diff","patch_url":"https://github.com/AnsibleShipyard/ansible-zookeeper/pull/29.patch","issue_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/29","number":29,"state":"closed","locked":false,"title":"Allow zookeeper hosts to accept list and hash","user":{"login":"ernestas-poskus","id":4499780,"avatar_url":"https://avatars.githubusercontent.com/u/4499780?v=3","gravatar_id":"","url":"https://api.github.com/users/ernestas-poskus","html_url":"https://github.com/ernestas-poskus","followers_url":"https://api.github.com/users/ernestas-poskus/followers","following_url":"https://api.github.com/users/ernestas-poskus/following{/other_user}","gists_url":"https://api.github.com/users/ernestas-poskus/gists{/gist_id}","starred_url":"https://api.github.com/users/ernestas-poskus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ernestas-poskus/subscriptions","organizations_url":"https://api.github.com/users/ernestas-poskus/orgs","repos_url":"https://api.github.com/users/ernestas-poskus/repos","events_url":"https://api.github.com/users/ernestas-poskus/events{/privacy}","received_events_url":"https://api.github.com/users/ernestas-poskus/received_events","type":"User","site_admin":false},"body":"@AnsibleShipyard/developers \r\n\r\ncc @sumantmurke (since I had this as dirty master for few weeks, decided to step in) @stevelle\r\n\r\nThis originates to https://github.com/ernestas-poskus/ansible-zookeeper/pull/1\r\n\r\n> All host had zoo_id as 1 by default as it used from default template hence all\r\nthe zookeeper nodes were not able to work with each other.\r\nThis fix will help operators to specify server id for host. This will help\r\nthem to configure the multinode zookeeper\r\nAlso cleaned up zoo.conf by replacing use of loop.index to use of server.id\r\nfor full consistency.\r\n\r\nI went step further and made hosts to accept both list & hash for convenience \r\n\r\nThis allows to manipulate hosts in a following manner:\r\n\r\n```yaml\r\n- name: Zookeeper\r\n  hosts: zookeepers\r\n  sudo: yes\r\n  roles:\r\n    - role: ansible-zookeeper\r\n      zookeeper_hosts: \"{{groups['zookeepers']}}\"\r\n```\r\n\r\nor \r\n\r\n```yaml\r\n- name: Zookeeper\r\n  hosts: zookeepers\r\n  sudo: yes\r\n  roles:\r\n    - role: ansible-zookeeper\r\n      zookeeper_hosts:\r\n        - id: 1\r\n          host: \"{{groups['zookeepers'][0]}}\"\r\n        - id: 2\r\n          host: \"{{groups['zookeepers'][1]}}\"\r\n        - id: 3\r\n          host: \"{{groups['zookeepers'][2]}}\"\r\n        - id: 4\r\n          host: \"{{groups['zookeepers'][3]}}\"\r\n```","created_at":"2016-06-01T20:12:04Z","updated_at":"2016-06-05T18:35:57Z","closed_at":"2016-06-05T18:35:57Z","merged_at":"2016-06-05T18:35:57Z","merge_commit_sha":"06f703ca1cc53c84a14e552e4495e99a4055aea3","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29/commits","review_comments_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29/comments","review_comment_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/comments{/number}","comments_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/29/comments","statuses_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/statuses/e3a103b7d0e30f662f2b1466f81812966170d4a5","head":{"label":"ernestas-poskus:features/allow_zookeeper_hosts_to_accept_list_and_hash","ref":"features/allow_zookeeper_hosts_to_accept_list_and_hash","sha":"e3a103b7d0e30f662f2b1466f81812966170d4a5","user":{"login":"ernestas-poskus","id":4499780,"avatar_url":"https://avatars.githubusercontent.com/u/4499780?v=3","gravatar_id":"","url":"https://api.github.com/users/ernestas-poskus","html_url":"https://github.com/ernestas-poskus","followers_url":"https://api.github.com/users/ernestas-poskus/followers","following_url":"https://api.github.com/users/ernestas-poskus/following{/other_user}","gists_url":"https://api.github.com/users/ernestas-poskus/gists{/gist_id}","starred_url":"https://api.github.com/users/ernestas-poskus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ernestas-poskus/subscriptions","organizations_url":"https://api.github.com/users/ernestas-poskus/orgs","repos_url":"https://api.github.com/users/ernestas-poskus/repos","events_url":"https://api.github.com/users/ernestas-poskus/events{/privacy}","received_events_url":"https://api.github.com/users/ernestas-poskus/received_events","type":"User","site_admin":false},"repo":{"id":54772003,"name":"ansible-zookeeper","full_name":"ernestas-poskus/ansible-zookeeper","owner":{"login":"ernestas-poskus","id":4499780,"avatar_url":"https://avatars.githubusercontent.com/u/4499780?v=3","gravatar_id":"","url":"https://api.github.com/users/ernestas-poskus","html_url":"https://github.com/ernestas-poskus","followers_url":"https://api.github.com/users/ernestas-poskus/followers","following_url":"https://api.github.com/users/ernestas-poskus/following{/other_user}","gists_url":"https://api.github.com/users/ernestas-poskus/gists{/gist_id}","starred_url":"https://api.github.com/users/ernestas-poskus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ernestas-poskus/subscriptions","organizations_url":"https://api.github.com/users/ernestas-poskus/orgs","repos_url":"https://api.github.com/users/ernestas-poskus/repos","events_url":"https://api.github.com/users/ernestas-poskus/events{/privacy}","received_events_url":"https://api.github.com/users/ernestas-poskus/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ernestas-poskus/ansible-zookeeper","description":"Ansible playbook for ZooKeeper","fork":true,"url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper","forks_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/forks","keys_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/teams","hooks_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/hooks","issue_events_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/issues/events{/number}","events_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/events","assignees_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/assignees{/user}","branches_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/branches{/branch}","tags_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/tags","blobs_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/git/refs{/sha}","trees_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/statuses/{sha}","languages_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/languages","stargazers_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/stargazers","contributors_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/contributors","subscribers_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/subscribers","subscription_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/subscription","commits_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/commits{/sha}","git_commits_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/git/commits{/sha}","comments_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/comments{/number}","issue_comment_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/issues/comments{/number}","contents_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/contents/{+path}","compare_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/merges","archive_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/downloads","issues_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/issues{/number}","pulls_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/pulls{/number}","milestones_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/milestones{/number}","notifications_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/labels{/name}","releases_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/releases{/id}","deployments_url":"https://api.github.com/repos/ernestas-poskus/ansible-zookeeper/deployments","created_at":"2016-03-26T09:24:59Z","updated_at":"2016-05-30T15:50:03Z","pushed_at":"2016-06-03T12:26:34Z","git_url":"git://github.com/ernestas-poskus/ansible-zookeeper.git","ssh_url":"git@github.com:ernestas-poskus/ansible-zookeeper.git","clone_url":"https://github.com/ernestas-poskus/ansible-zookeeper.git","svn_url":"https://github.com/ernestas-poskus/ansible-zookeeper","homepage":null,"size":28,"stargazers_count":1,"watchers_count":1,"language":"Shell","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"AnsibleShipyard:master","ref":"master","sha":"24c3a25003a31a4ebe7fa8e80358070163b68b01","user":{"login":"AnsibleShipyard","id":6966875,"avatar_url":"https://avatars.githubusercontent.com/u/6966875?v=3","gravatar_id":"","url":"https://api.github.com/users/AnsibleShipyard","html_url":"https://github.com/AnsibleShipyard","followers_url":"https://api.github.com/users/AnsibleShipyard/followers","following_url":"https://api.github.com/users/AnsibleShipyard/following{/other_user}","gists_url":"https://api.github.com/users/AnsibleShipyard/gists{/gist_id}","starred_url":"https://api.github.com/users/AnsibleShipyard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnsibleShipyard/subscriptions","organizations_url":"https://api.github.com/users/AnsibleShipyard/orgs","repos_url":"https://api.github.com/users/AnsibleShipyard/repos","events_url":"https://api.github.com/users/AnsibleShipyard/events{/privacy}","received_events_url":"https://api.github.com/users/AnsibleShipyard/received_events","type":"Organization","site_admin":false},"repo":{"id":23445857,"name":"ansible-zookeeper","full_name":"AnsibleShipyard/ansible-zookeeper","owner":{"login":"AnsibleShipyard","id":6966875,"avatar_url":"https://avatars.githubusercontent.com/u/6966875?v=3","gravatar_id":"","url":"https://api.github.com/users/AnsibleShipyard","html_url":"https://github.com/AnsibleShipyard","followers_url":"https://api.github.com/users/AnsibleShipyard/followers","following_url":"https://api.github.com/users/AnsibleShipyard/following{/other_user}","gists_url":"https://api.github.com/users/AnsibleShipyard/gists{/gist_id}","starred_url":"https://api.github.com/users/AnsibleShipyard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnsibleShipyard/subscriptions","organizations_url":"https://api.github.com/users/AnsibleShipyard/orgs","repos_url":"https://api.github.com/users/AnsibleShipyard/repos","events_url":"https://api.github.com/users/AnsibleShipyard/events{/privacy}","received_events_url":"https://api.github.com/users/AnsibleShipyard/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/AnsibleShipyard/ansible-zookeeper","description":"Ansible playbook for ZooKeeper","fork":true,"url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper","forks_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/forks","keys_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/teams","hooks_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/hooks","issue_events_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/events{/number}","events_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/events","assignees_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/assignees{/user}","branches_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/branches{/branch}","tags_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/tags","blobs_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/git/refs{/sha}","trees_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/statuses/{sha}","languages_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/languages","stargazers_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/stargazers","contributors_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/contributors","subscribers_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/subscribers","subscription_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/subscription","commits_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/commits{/sha}","git_commits_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/git/commits{/sha}","comments_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/comments{/number}","issue_comment_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/comments{/number}","contents_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/contents/{+path}","compare_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/merges","archive_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/downloads","issues_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues{/number}","pulls_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls{/number}","milestones_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/milestones{/number}","notifications_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/labels{/name}","releases_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/releases{/id}","deployments_url":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/deployments","created_at":"2014-08-28T23:10:41Z","updated_at":"2016-05-30T15:50:01Z","pushed_at":"2016-06-05T18:35:57Z","git_url":"git://github.com/AnsibleShipyard/ansible-zookeeper.git","ssh_url":"git@github.com:AnsibleShipyard/ansible-zookeeper.git","clone_url":"https://github.com/AnsibleShipyard/ansible-zookeeper.git","svn_url":"https://github.com/AnsibleShipyard/ansible-zookeeper","homepage":null,"size":36,"stargazers_count":24,"watchers_count":24,"language":"Shell","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":50,"mirror_url":null,"open_issues_count":7,"forks":50,"open_issues":7,"watchers":24,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29"},"html":{"href":"https://github.com/AnsibleShipyard/ansible-zookeeper/pull/29"},"issue":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/29"},"comments":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/issues/29/comments"},"review_comments":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29/comments"},"review_comment":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/pulls/29/commits"},"statuses":{"href":"https://api.github.com/repos/AnsibleShipyard/ansible-zookeeper/statuses/e3a103b7d0e30f662f2b1466f81812966170d4a5"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"ernestas-poskus","id":4499780,"avatar_url":"https://avatars.githubusercontent.com/u/4499780?v=3","gravatar_id":"","url":"https://api.github.com/users/ernestas-poskus","html_url":"https://github.com/ernestas-poskus","followers_url":"https://api.github.com/users/ernestas-poskus/followers","following_url":"https://api.github.com/users/ernestas-poskus/following{/other_user}","gists_url":"https://api.github.com/users/ernestas-poskus/gists{/gist_id}","starred_url":"https://api.github.com/users/ernestas-poskus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ernestas-poskus/subscriptions","organizations_url":"https://api.github.com/users/ernestas-poskus/orgs","repos_url":"https://api.github.com/users/ernestas-poskus/repos","events_url":"https://api.github.com/users/ernestas-poskus/events{/privacy}","received_events_url":"https://api.github.com/users/ernestas-poskus/received_events","type":"User","site_admin":false},"comments":5,"review_comments":0,"commits":1,"additions":70,"deletions":14,"changed_files":6}}
{"actor":{"display_login":"ernestas-poskus"}}