GitHub PullRequestReviewCommentEvent at 2014-11-15 04:10:15
Repository: buildbot-infra
Actor: seankelly
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/comments/20399863","id":20399863,"diff_hunk":"@@ -0,0 +1,18 @@\n+Don't Know How To..\n+-------------------\n+\n+* handle secrets\n+* purge unhandled things (users)\n+  (apparently not supported directly by ansible; workarounds involve lots of\n+  scripting)\n+\n+Bootstrapping Ideas\n+-------------------\n+\n+Logging in remotely is hard -- probably non-priv SSH + `su -`.  Can ansible do\n+that?\n+\n+Ah, see http://lampros.chaidas.com/index.php/2014/06/ for raw mode\n+\n+Need 'pkg install python ansible' -- ansible only dep's python2-2_3, which","path":"docs/ansible-notes.txt","position":17,"original_position":17,"commit_id":"60ceb52e2d5ba1faf0d9a35476d4b64a7ff86736","original_commit_id":"60ceb52e2d5ba1faf0d9a35476d4b64a7ff86736","user":{"login":"seankelly","id":93281,"avatar_url":"https://avatars.githubusercontent.com/u/93281?v=3","gravatar_id":"","url":"https://api.github.com/users/seankelly","html_url":"https://github.com/seankelly","followers_url":"https://api.github.com/users/seankelly/followers","following_url":"https://api.github.com/users/seankelly/following{/other_user}","gists_url":"https://api.github.com/users/seankelly/gists{/gist_id}","starred_url":"https://api.github.com/users/seankelly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seankelly/subscriptions","organizations_url":"https://api.github.com/users/seankelly/orgs","repos_url":"https://api.github.com/users/seankelly/repos","events_url":"https://api.github.com/users/seankelly/events{/privacy}","received_events_url":"https://api.github.com/users/seankelly/received_events","type":"User","site_admin":false},"body":"The hosts file does set ansible_python_interpreter to python2.7.","created_at":"2014-11-15T04:10:15Z","updated_at":"2014-11-15T04:10:15Z","html_url":"https://github.com/buildbot/buildbot-infra/pull/5#discussion_r20399863","pull_request_url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/comments/20399863"},"html":{"href":"https://github.com/buildbot/buildbot-infra/pull/5#discussion_r20399863"},"pull_request":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5","id":24482518,"html_url":"https://github.com/buildbot/buildbot-infra/pull/5","diff_url":"https://github.com/buildbot/buildbot-infra/pull/5.diff","patch_url":"https://github.com/buildbot/buildbot-infra/pull/5.patch","issue_url":"https://api.github.com/repos/buildbot/buildbot-infra/issues/5","number":5,"state":"open","locked":false,"title":"Initial Ansible setup","user":{"login":"djmitche","id":28673,"avatar_url":"https://avatars.githubusercontent.com/u/28673?v=3","gravatar_id":"","url":"https://api.github.com/users/djmitche","html_url":"https://github.com/djmitche","followers_url":"https://api.github.com/users/djmitche/followers","following_url":"https://api.github.com/users/djmitche/following{/other_user}","gists_url":"https://api.github.com/users/djmitche/gists{/gist_id}","starred_url":"https://api.github.com/users/djmitche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djmitche/subscriptions","organizations_url":"https://api.github.com/users/djmitche/orgs","repos_url":"https://api.github.com/users/djmitche/repos","events_url":"https://api.github.com/users/djmitche/events{/privacy}","received_events_url":"https://api.github.com/users/djmitche/received_events","type":"User","site_admin":false},"body":"This doesn't do a whole lot just at the moment:\r\n * set up sshd with keys\r\n * set up sudo and sudoers\r\n * install Python (required for ansible)\r\n..and only does so on the service hosts.\r\n\r\nI've played with other necessary bits a little (jails, bootstrapping Ansible, handling secrets, etc.), but I want to start very small so that we can review each increment carefully.\r\n\r\nThings various of you may not like:\r\n * using 'sudo' instead of 'su': this eliminates the need for anyone to know or type any passwords\r\n * use of `group_vars/all` for things like admin users\r\n * hardcoded hosts might make staging/development hard\r\n\r\nAnyway, I'd like to commit this and then run it against the service hosts.  @verm?  @seankelly?  @sa2ajj?\r\n\r\nHere's the output of a -C run (using -S which requires typing a shared password every time - blech)\r\n```\r\n(sandbox)dustin@ramanujan ~/code/buildbot/t/infra [init-ansible*] $ ansible-playbook -f 5 -C -S site.yml --ask-su-pass\r\nsu password: \r\n\r\nPLAY [servicehosts] *********************************************************** \r\n\r\nGATHERING FACTS *************************************************************** \r\nok: [service2.buildbot.net]\r\nok: [service1.buildbot.net]\r\nok: [service3.buildbot.net]\r\n\r\nTASK: [base | install python] ************************************************* \r\nchanged: [service1.buildbot.net]\r\nchanged: [service3.buildbot.net]\r\nchanged: [service2.buildbot.net]\r\n\r\nTASK: [base | install sudo] *************************************************** \r\nok: [service1.buildbot.net]\r\nok: [service3.buildbot.net]\r\nok: [service2.buildbot.net]\r\n\r\nTASK: [base | configure sudo] ************************************************* \r\nchanged: [service3.buildbot.net]\r\nchanged: [service1.buildbot.net]\r\nchanged: [service2.buildbot.net]\r\n\r\nTASK: [base | add/remove administrative users] ******************************** \r\nok: [service3.buildbot.net] => (item={'username': 'john', 'state': 'absent'})\r\nok: [service1.buildbot.net] => (item={'username': 'john', 'state': 'absent'})\r\nok: [service2.buildbot.net] => (item={'username': 'john', 'state': 'absent'})\r\nok: [service3.buildbot.net] => (item={'username': 'jim', 'state': 'absent'})\r\nok: [service1.buildbot.net] => (item={'username': 'jim', 'state': 'absent'})\r\nok: [service2.buildbot.net] => (item={'username': 'jim', 'state': 'absent'})\r\nok: [service3.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nok: [service1.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nok: [service2.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nok: [service3.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nok: [service1.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nok: [service2.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nchanged: [service3.buildbot.net] => (item={'username': 'mss', 'state': 'present'})\r\nchanged: [service1.buildbot.net] => (item={'username': 'mss', 'state': 'present'})\r\nchanged: [service2.buildbot.net] => (item={'username': 'mss', 'state': 'present'})\r\n\r\nTASK: [base | add administrative users' SSH keys] ***************************** \r\nchanged: [service3.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nchanged: [service1.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nchanged: [service2.buildbot.net] => (item={'username': 'dustin', 'state': 'present'})\r\nok: [service3.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nok: [service1.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nok: [service2.buildbot.net] => (item={'username': 'amar', 'state': 'present'})\r\nfailed: [service3.buildbot.net] => (item={'username': 'mss', 'state': 'present'}) => {\"failed\": true, \"item\": {\"state\": \"present\", \"username\": \"mss\"}}\r\nmsg: Failed to lookup user mss: 'getpwnam(): name not found: mss'\r\nfailed: [service1.buildbot.net] => (item={'username': 'mss', 'state': 'present'}) => {\"failed\": true, \"item\": {\"state\": \"present\", \"username\": \"mss\"}}\r\nmsg: Failed to lookup user mss: 'getpwnam(): name not found: mss'\r\nok: [service2.buildbot.net] => (item={'username': 'mss', 'state': 'present'})\r\n\r\nTASK: [ssh | sshd configuration] ********************************************** \r\nchanged: [service2.buildbot.net]\r\n\r\nTASK: [ssh | enable sshd] ***************************************************** \r\nok: [service2.buildbot.net]\r\n\r\nNOTIFIED: [ssh | restart sshd] ************************************************ \r\nchanged: [service2.buildbot.net]\r\n\r\nPLAY RECAP ******************************************************************** \r\n           to retry, use: --limit @/home/dustin/site.retry\r\n\r\nservice1.buildbot.net      : ok=5    changed=3    unreachable=0    failed=1   \r\nservice2.buildbot.net      : ok=9    changed=6    unreachable=0    failed=0   \r\nservice3.buildbot.net      : ok=5    changed=3    unreachable=0    failed=1   \r\n\r\n(sandbox)dustin@ramanujan ~/code/buildbot/t/infra [init-ansible*] $\r\n```","created_at":"2014-11-15T01:31:44Z","updated_at":"2014-11-15T04:10:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"37776de26476a06531701974d83bf11d8080d93d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5/commits","review_comments_url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5/comments","review_comment_url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/comments/{number}","comments_url":"https://api.github.com/repos/buildbot/buildbot-infra/issues/5/comments","statuses_url":"https://api.github.com/repos/buildbot/buildbot-infra/statuses/60ceb52e2d5ba1faf0d9a35476d4b64a7ff86736","head":{"label":"djmitche:init-ansible","ref":"init-ansible","sha":"60ceb52e2d5ba1faf0d9a35476d4b64a7ff86736","user":{"login":"djmitche","id":28673,"avatar_url":"https://avatars.githubusercontent.com/u/28673?v=3","gravatar_id":"","url":"https://api.github.com/users/djmitche","html_url":"https://github.com/djmitche","followers_url":"https://api.github.com/users/djmitche/followers","following_url":"https://api.github.com/users/djmitche/following{/other_user}","gists_url":"https://api.github.com/users/djmitche/gists{/gist_id}","starred_url":"https://api.github.com/users/djmitche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djmitche/subscriptions","organizations_url":"https://api.github.com/users/djmitche/orgs","repos_url":"https://api.github.com/users/djmitche/repos","events_url":"https://api.github.com/users/djmitche/events{/privacy}","received_events_url":"https://api.github.com/users/djmitche/received_events","type":"User","site_admin":false},"repo":{"id":25138897,"name":"buildbot-infra","full_name":"djmitche/buildbot-infra","owner":{"login":"djmitche","id":28673,"avatar_url":"https://avatars.githubusercontent.com/u/28673?v=3","gravatar_id":"","url":"https://api.github.com/users/djmitche","html_url":"https://github.com/djmitche","followers_url":"https://api.github.com/users/djmitche/followers","following_url":"https://api.github.com/users/djmitche/following{/other_user}","gists_url":"https://api.github.com/users/djmitche/gists{/gist_id}","starred_url":"https://api.github.com/users/djmitche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djmitche/subscriptions","organizations_url":"https://api.github.com/users/djmitche/orgs","repos_url":"https://api.github.com/users/djmitche/repos","events_url":"https://api.github.com/users/djmitche/events{/privacy}","received_events_url":"https://api.github.com/users/djmitche/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/djmitche/buildbot-infra","description":"Buildbot infrastructure","fork":true,"url":"https://api.github.com/repos/djmitche/buildbot-infra","forks_url":"https://api.github.com/repos/djmitche/buildbot-infra/forks","keys_url":"https://api.github.com/repos/djmitche/buildbot-infra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/djmitche/buildbot-infra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/djmitche/buildbot-infra/teams","hooks_url":"https://api.github.com/repos/djmitche/buildbot-infra/hooks","issue_events_url":"https://api.github.com/repos/djmitche/buildbot-infra/issues/events{/number}","events_url":"https://api.github.com/repos/djmitche/buildbot-infra/events","assignees_url":"https://api.github.com/repos/djmitche/buildbot-infra/assignees{/user}","branches_url":"https://api.github.com/repos/djmitche/buildbot-infra/branches{/branch}","tags_url":"https://api.github.com/repos/djmitche/buildbot-infra/tags","blobs_url":"https://api.github.com/repos/djmitche/buildbot-infra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/djmitche/buildbot-infra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/djmitche/buildbot-infra/git/refs{/sha}","trees_url":"https://api.github.com/repos/djmitche/buildbot-infra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/djmitche/buildbot-infra/statuses/{sha}","languages_url":"https://api.github.com/repos/djmitche/buildbot-infra/languages","stargazers_url":"https://api.github.com/repos/djmitche/buildbot-infra/stargazers","contributors_url":"https://api.github.com/repos/djmitche/buildbot-infra/contributors","subscribers_url":"https://api.github.com/repos/djmitche/buildbot-infra/subscribers","subscription_url":"https://api.github.com/repos/djmitche/buildbot-infra/subscription","commits_url":"https://api.github.com/repos/djmitche/buildbot-infra/commits{/sha}","git_commits_url":"https://api.github.com/repos/djmitche/buildbot-infra/git/commits{/sha}","comments_url":"https://api.github.com/repos/djmitche/buildbot-infra/comments{/number}","issue_comment_url":"https://api.github.com/repos/djmitche/buildbot-infra/issues/comments/{number}","contents_url":"https://api.github.com/repos/djmitche/buildbot-infra/contents/{+path}","compare_url":"https://api.github.com/repos/djmitche/buildbot-infra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/djmitche/buildbot-infra/merges","archive_url":"https://api.github.com/repos/djmitche/buildbot-infra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/djmitche/buildbot-infra/downloads","issues_url":"https://api.github.com/repos/djmitche/buildbot-infra/issues{/number}","pulls_url":"https://api.github.com/repos/djmitche/buildbot-infra/pulls{/number}","milestones_url":"https://api.github.com/repos/djmitche/buildbot-infra/milestones{/number}","notifications_url":"https://api.github.com/repos/djmitche/buildbot-infra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/djmitche/buildbot-infra/labels{/name}","releases_url":"https://api.github.com/repos/djmitche/buildbot-infra/releases{/id}","created_at":"2014-10-13T01:54:34Z","updated_at":"2014-11-04T00:23:58Z","pushed_at":"2014-11-15T03:03:21Z","git_url":"git://github.com/djmitche/buildbot-infra.git","ssh_url":"git@github.com:djmitche/buildbot-infra.git","clone_url":"https://github.com/djmitche/buildbot-infra.git","svn_url":"https://github.com/djmitche/buildbot-infra","homepage":null,"size":185,"stargazers_count":0,"watchers_count":0,"language":"AGS Script","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"buildbot:master","ref":"master","sha":"3cadb5e01bc5ece2ebb3213cdded44a5d54e51b8","user":{"login":"buildbot","id":324515,"avatar_url":"https://avatars.githubusercontent.com/u/324515?v=3","gravatar_id":"","url":"https://api.github.com/users/buildbot","html_url":"https://github.com/buildbot","followers_url":"https://api.github.com/users/buildbot/followers","following_url":"https://api.github.com/users/buildbot/following{/other_user}","gists_url":"https://api.github.com/users/buildbot/gists{/gist_id}","starred_url":"https://api.github.com/users/buildbot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/buildbot/subscriptions","organizations_url":"https://api.github.com/users/buildbot/orgs","repos_url":"https://api.github.com/users/buildbot/repos","events_url":"https://api.github.com/users/buildbot/events{/privacy}","received_events_url":"https://api.github.com/users/buildbot/received_events","type":"Organization","site_admin":false},"repo":{"id":25138762,"name":"buildbot-infra","full_name":"buildbot/buildbot-infra","owner":{"login":"buildbot","id":324515,"avatar_url":"https://avatars.githubusercontent.com/u/324515?v=3","gravatar_id":"","url":"https://api.github.com/users/buildbot","html_url":"https://github.com/buildbot","followers_url":"https://api.github.com/users/buildbot/followers","following_url":"https://api.github.com/users/buildbot/following{/other_user}","gists_url":"https://api.github.com/users/buildbot/gists{/gist_id}","starred_url":"https://api.github.com/users/buildbot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/buildbot/subscriptions","organizations_url":"https://api.github.com/users/buildbot/orgs","repos_url":"https://api.github.com/users/buildbot/repos","events_url":"https://api.github.com/users/buildbot/events{/privacy}","received_events_url":"https://api.github.com/users/buildbot/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/buildbot/buildbot-infra","description":"Buildbot infrastructure","fork":false,"url":"https://api.github.com/repos/buildbot/buildbot-infra","forks_url":"https://api.github.com/repos/buildbot/buildbot-infra/forks","keys_url":"https://api.github.com/repos/buildbot/buildbot-infra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/buildbot/buildbot-infra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/buildbot/buildbot-infra/teams","hooks_url":"https://api.github.com/repos/buildbot/buildbot-infra/hooks","issue_events_url":"https://api.github.com/repos/buildbot/buildbot-infra/issues/events{/number}","events_url":"https://api.github.com/repos/buildbot/buildbot-infra/events","assignees_url":"https://api.github.com/repos/buildbot/buildbot-infra/assignees{/user}","branches_url":"https://api.github.com/repos/buildbot/buildbot-infra/branches{/branch}","tags_url":"https://api.github.com/repos/buildbot/buildbot-infra/tags","blobs_url":"https://api.github.com/repos/buildbot/buildbot-infra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/buildbot/buildbot-infra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/buildbot/buildbot-infra/git/refs{/sha}","trees_url":"https://api.github.com/repos/buildbot/buildbot-infra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/buildbot/buildbot-infra/statuses/{sha}","languages_url":"https://api.github.com/repos/buildbot/buildbot-infra/languages","stargazers_url":"https://api.github.com/repos/buildbot/buildbot-infra/stargazers","contributors_url":"https://api.github.com/repos/buildbot/buildbot-infra/contributors","subscribers_url":"https://api.github.com/repos/buildbot/buildbot-infra/subscribers","subscription_url":"https://api.github.com/repos/buildbot/buildbot-infra/subscription","commits_url":"https://api.github.com/repos/buildbot/buildbot-infra/commits{/sha}","git_commits_url":"https://api.github.com/repos/buildbot/buildbot-infra/git/commits{/sha}","comments_url":"https://api.github.com/repos/buildbot/buildbot-infra/comments{/number}","issue_comment_url":"https://api.github.com/repos/buildbot/buildbot-infra/issues/comments/{number}","contents_url":"https://api.github.com/repos/buildbot/buildbot-infra/contents/{+path}","compare_url":"https://api.github.com/repos/buildbot/buildbot-infra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/buildbot/buildbot-infra/merges","archive_url":"https://api.github.com/repos/buildbot/buildbot-infra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/buildbot/buildbot-infra/downloads","issues_url":"https://api.github.com/repos/buildbot/buildbot-infra/issues{/number}","pulls_url":"https://api.github.com/repos/buildbot/buildbot-infra/pulls{/number}","milestones_url":"https://api.github.com/repos/buildbot/buildbot-infra/milestones{/number}","notifications_url":"https://api.github.com/repos/buildbot/buildbot-infra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/buildbot/buildbot-infra/labels{/name}","releases_url":"https://api.github.com/repos/buildbot/buildbot-infra/releases{/id}","created_at":"2014-10-13T01:49:51Z","updated_at":"2014-10-23T21:51:59Z","pushed_at":"2014-11-15T01:18:48Z","git_url":"git://github.com/buildbot/buildbot-infra.git","ssh_url":"git@github.com:buildbot/buildbot-infra.git","clone_url":"https://github.com/buildbot/buildbot-infra.git","svn_url":"https://github.com/buildbot/buildbot-infra","homepage":null,"size":251,"stargazers_count":0,"watchers_count":0,"language":"AGS Script","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":1,"forks":3,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5"},"html":{"href":"https://github.com/buildbot/buildbot-infra/pull/5"},"issue":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/issues/5"},"comments":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/buildbot/buildbot-infra/statuses/60ceb52e2d5ba1faf0d9a35476d4b64a7ff86736"}}}}