GitHub PullRequestEvent at 2014-06-22 17:28:12
Repository: chef
Actor: btm
Payload: {"action":"closed","number":1530,"pull_request":{"url":"https://api.github.com/repos/opscode/chef/pulls/1530","id":17429191,"html_url":"https://github.com/opscode/chef/pull/1530","diff_url":"https://github.com/opscode/chef/pull/1530.diff","patch_url":"https://github.com/opscode/chef/pull/1530.patch","issue_url":"https://api.github.com/repos/opscode/chef/issues/1530","number":1530,"state":"closed","title":"CHEF-5158: Prefer CLI argument over configuration file setting for ssh_attribute","user":{"login":"btm","id":4381,"avatar_url":"https://avatars.githubusercontent.com/u/4381?","gravatar_id":"4e4adb8dd390e1daecb15a67f05ae0d1","url":"https://api.github.com/users/btm","html_url":"https://github.com/btm","followers_url":"https://api.github.com/users/btm/followers","following_url":"https://api.github.com/users/btm/following{/other_user}","gists_url":"https://api.github.com/users/btm/gists{/gist_id}","starred_url":"https://api.github.com/users/btm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btm/subscriptions","organizations_url":"https://api.github.com/users/btm/orgs","repos_url":"https://api.github.com/users/btm/repos","events_url":"https://api.github.com/users/btm/events{/privacy}","received_events_url":"https://api.github.com/users/btm/received_events","type":"User","site_admin":false},"body":"Builds slightly on #1379 by changing an internal attribute name to something more specific and self-explanatory. Also adds debug messages regarding which was chosen.\r\n\r\nManual testing:\r\n\r\nCorrectly uses node[:cloud][:public_hostname] if it exists:\r\n```\r\n$ knife ssh name:i-5f4cf274 -x ubuntu hostname\r\nec2-107-20-12-157.compute-1.amazonaws.com domU-12-31-39-06-C1-62\r\n```\r\n\r\nBut lets you override that on the command line (expected to fail here):\r\n```\r\n$ knife ssh name:i-5f4cf274 -a ipaddress -x ubuntu hostname\r\nWARNING: Failed to connect to 10.208.198.144 -- Net::SSH::ConnectionTimeout: execution expired for 10.208.198.144\r\n```\r\n\r\nknife.rb contains this, which means we are correctly taking the CLI argument and using node[:cloud][:public_hostname] over the configuration file in both examples above --^\r\n```\r\nknife[:ssh_attribute] = \"ipaddress\"\r\n```\r\n\r\nOff the cloud, the above config is read correctly when no command line is specified:\r\n```\r\n$ knife ssh name:btm-mbp-dev.foo.org hostname\r\n172.16.151.100 btm-mbp-dev\r\n```\r\n\r\nOtherwise it correctly defaults to fqdn:\r\n```\r\n$ knife ssh name:btm-mbp-dev.foo.org hostname\r\nbtm-mbp-dev.foo.org btm-mbp-dev\r\n```","created_at":"2014-06-20T21:35:34Z","updated_at":"2014-06-22T17:28:11Z","closed_at":"2014-06-22T17:28:11Z","merged_at":"2014-06-22T17:28:11Z","merge_commit_sha":"8857df8a8379cbf4f655bbf6a3a519e2f728b1c0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/opscode/chef/pulls/1530/commits","review_comments_url":"https://api.github.com/repos/opscode/chef/pulls/1530/comments","review_comment_url":"https://api.github.com/repos/opscode/chef/pulls/comments/{number}","comments_url":"https://api.github.com/repos/opscode/chef/issues/1530/comments","statuses_url":"https://api.github.com/repos/opscode/chef/statuses/ec30afbca5c31953975c45b2d0efde01223541cc","head":{"label":"opscode:btm/CHEF-5158","ref":"btm/CHEF-5158","sha":"ec30afbca5c31953975c45b2d0efde01223541cc","user":{"login":"opscode","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?","gravatar_id":"890bf76f4dc18c12a19c55e988a1bd5e","url":"https://api.github.com/users/opscode","html_url":"https://github.com/opscode","followers_url":"https://api.github.com/users/opscode/followers","following_url":"https://api.github.com/users/opscode/following{/other_user}","gists_url":"https://api.github.com/users/opscode/gists{/gist_id}","starred_url":"https://api.github.com/users/opscode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opscode/subscriptions","organizations_url":"https://api.github.com/users/opscode/orgs","repos_url":"https://api.github.com/users/opscode/repos","events_url":"https://api.github.com/users/opscode/events{/privacy}","received_events_url":"https://api.github.com/users/opscode/received_events","type":"Organization","site_admin":false},"repo":{"id":108278,"name":"chef","full_name":"opscode/chef","owner":{"login":"opscode","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?","gravatar_id":"890bf76f4dc18c12a19c55e988a1bd5e","url":"https://api.github.com/users/opscode","html_url":"https://github.com/opscode","followers_url":"https://api.github.com/users/opscode/followers","following_url":"https://api.github.com/users/opscode/following{/other_user}","gists_url":"https://api.github.com/users/opscode/gists{/gist_id}","starred_url":"https://api.github.com/users/opscode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opscode/subscriptions","organizations_url":"https://api.github.com/users/opscode/orgs","repos_url":"https://api.github.com/users/opscode/repos","events_url":"https://api.github.com/users/opscode/events{/privacy}","received_events_url":"https://api.github.com/users/opscode/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opscode/chef","description":"A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure.","fork":false,"url":"https://api.github.com/repos/opscode/chef","forks_url":"https://api.github.com/repos/opscode/chef/forks","keys_url":"https://api.github.com/repos/opscode/chef/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opscode/chef/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opscode/chef/teams","hooks_url":"https://api.github.com/repos/opscode/chef/hooks","issue_events_url":"https://api.github.com/repos/opscode/chef/issues/events{/number}","events_url":"https://api.github.com/repos/opscode/chef/events","assignees_url":"https://api.github.com/repos/opscode/chef/assignees{/user}","branches_url":"https://api.github.com/repos/opscode/chef/branches{/branch}","tags_url":"https://api.github.com/repos/opscode/chef/tags","blobs_url":"https://api.github.com/repos/opscode/chef/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opscode/chef/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opscode/chef/git/refs{/sha}","trees_url":"https://api.github.com/repos/opscode/chef/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opscode/chef/statuses/{sha}","languages_url":"https://api.github.com/repos/opscode/chef/languages","stargazers_url":"https://api.github.com/repos/opscode/chef/stargazers","contributors_url":"https://api.github.com/repos/opscode/chef/contributors","subscribers_url":"https://api.github.com/repos/opscode/chef/subscribers","subscription_url":"https://api.github.com/repos/opscode/chef/subscription","commits_url":"https://api.github.com/repos/opscode/chef/commits{/sha}","git_commits_url":"https://api.github.com/repos/opscode/chef/git/commits{/sha}","comments_url":"https://api.github.com/repos/opscode/chef/comments{/number}","issue_comment_url":"https://api.github.com/repos/opscode/chef/issues/comments/{number}","contents_url":"https://api.github.com/repos/opscode/chef/contents/{+path}","compare_url":"https://api.github.com/repos/opscode/chef/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opscode/chef/merges","archive_url":"https://api.github.com/repos/opscode/chef/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opscode/chef/downloads","issues_url":"https://api.github.com/repos/opscode/chef/issues{/number}","pulls_url":"https://api.github.com/repos/opscode/chef/pulls{/number}","milestones_url":"https://api.github.com/repos/opscode/chef/milestones{/number}","notifications_url":"https://api.github.com/repos/opscode/chef/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opscode/chef/labels{/name}","releases_url":"https://api.github.com/repos/opscode/chef/releases{/id}","created_at":"2009-01-15T20:40:48Z","updated_at":"2014-06-22T17:28:11Z","pushed_at":"2014-06-22T17:28:11Z","git_url":"git://github.com/opscode/chef.git","ssh_url":"git@github.com:opscode/chef.git","clone_url":"https://github.com/opscode/chef.git","svn_url":"https://github.com/opscode/chef","homepage":"http://www.getchef.com/chef/","size":138433,"stargazers_count":2756,"watchers_count":2756,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"forks_count":1142,"mirror_url":null,"open_issues_count":104,"forks":1142,"open_issues":104,"watchers":2756,"default_branch":"master"}},"base":{"label":"opscode:master","ref":"master","sha":"f6730f41b46fb9f3ffa5c6fea71d90b5964e779b","user":{"login":"opscode","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?","gravatar_id":"890bf76f4dc18c12a19c55e988a1bd5e","url":"https://api.github.com/users/opscode","html_url":"https://github.com/opscode","followers_url":"https://api.github.com/users/opscode/followers","following_url":"https://api.github.com/users/opscode/following{/other_user}","gists_url":"https://api.github.com/users/opscode/gists{/gist_id}","starred_url":"https://api.github.com/users/opscode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opscode/subscriptions","organizations_url":"https://api.github.com/users/opscode/orgs","repos_url":"https://api.github.com/users/opscode/repos","events_url":"https://api.github.com/users/opscode/events{/privacy}","received_events_url":"https://api.github.com/users/opscode/received_events","type":"Organization","site_admin":false},"repo":{"id":108278,"name":"chef","full_name":"opscode/chef","owner":{"login":"opscode","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?","gravatar_id":"890bf76f4dc18c12a19c55e988a1bd5e","url":"https://api.github.com/users/opscode","html_url":"https://github.com/opscode","followers_url":"https://api.github.com/users/opscode/followers","following_url":"https://api.github.com/users/opscode/following{/other_user}","gists_url":"https://api.github.com/users/opscode/gists{/gist_id}","starred_url":"https://api.github.com/users/opscode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opscode/subscriptions","organizations_url":"https://api.github.com/users/opscode/orgs","repos_url":"https://api.github.com/users/opscode/repos","events_url":"https://api.github.com/users/opscode/events{/privacy}","received_events_url":"https://api.github.com/users/opscode/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/opscode/chef","description":"A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure.","fork":false,"url":"https://api.github.com/repos/opscode/chef","forks_url":"https://api.github.com/repos/opscode/chef/forks","keys_url":"https://api.github.com/repos/opscode/chef/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opscode/chef/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opscode/chef/teams","hooks_url":"https://api.github.com/repos/opscode/chef/hooks","issue_events_url":"https://api.github.com/repos/opscode/chef/issues/events{/number}","events_url":"https://api.github.com/repos/opscode/chef/events","assignees_url":"https://api.github.com/repos/opscode/chef/assignees{/user}","branches_url":"https://api.github.com/repos/opscode/chef/branches{/branch}","tags_url":"https://api.github.com/repos/opscode/chef/tags","blobs_url":"https://api.github.com/repos/opscode/chef/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opscode/chef/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opscode/chef/git/refs{/sha}","trees_url":"https://api.github.com/repos/opscode/chef/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opscode/chef/statuses/{sha}","languages_url":"https://api.github.com/repos/opscode/chef/languages","stargazers_url":"https://api.github.com/repos/opscode/chef/stargazers","contributors_url":"https://api.github.com/repos/opscode/chef/contributors","subscribers_url":"https://api.github.com/repos/opscode/chef/subscribers","subscription_url":"https://api.github.com/repos/opscode/chef/subscription","commits_url":"https://api.github.com/repos/opscode/chef/commits{/sha}","git_commits_url":"https://api.github.com/repos/opscode/chef/git/commits{/sha}","comments_url":"https://api.github.com/repos/opscode/chef/comments{/number}","issue_comment_url":"https://api.github.com/repos/opscode/chef/issues/comments/{number}","contents_url":"https://api.github.com/repos/opscode/chef/contents/{+path}","compare_url":"https://api.github.com/repos/opscode/chef/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opscode/chef/merges","archive_url":"https://api.github.com/repos/opscode/chef/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opscode/chef/downloads","issues_url":"https://api.github.com/repos/opscode/chef/issues{/number}","pulls_url":"https://api.github.com/repos/opscode/chef/pulls{/number}","milestones_url":"https://api.github.com/repos/opscode/chef/milestones{/number}","notifications_url":"https://api.github.com/repos/opscode/chef/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opscode/chef/labels{/name}","releases_url":"https://api.github.com/repos/opscode/chef/releases{/id}","created_at":"2009-01-15T20:40:48Z","updated_at":"2014-06-22T17:28:11Z","pushed_at":"2014-06-22T17:28:11Z","git_url":"git://github.com/opscode/chef.git","ssh_url":"git@github.com:opscode/chef.git","clone_url":"https://github.com/opscode/chef.git","svn_url":"https://github.com/opscode/chef","homepage":"http://www.getchef.com/chef/","size":138433,"stargazers_count":2756,"watchers_count":2756,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"forks_count":1142,"mirror_url":null,"open_issues_count":104,"forks":1142,"open_issues":104,"watchers":2756,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/opscode/chef/pulls/1530"},"html":{"href":"https://github.com/opscode/chef/pull/1530"},"issue":{"href":"https://api.github.com/repos/opscode/chef/issues/1530"},"comments":{"href":"https://api.github.com/repos/opscode/chef/issues/1530/comments"},"review_comments":{"href":"https://api.github.com/repos/opscode/chef/pulls/1530/comments"},"review_comment":{"href":"https://api.github.com/repos/opscode/chef/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/opscode/chef/pulls/1530/commits"},"statuses":{"href":"https://api.github.com/repos/opscode/chef/statuses/ec30afbca5c31953975c45b2d0efde01223541cc"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"btm","id":4381,"avatar_url":"https://avatars.githubusercontent.com/u/4381?","gravatar_id":"4e4adb8dd390e1daecb15a67f05ae0d1","url":"https://api.github.com/users/btm","html_url":"https://github.com/btm","followers_url":"https://api.github.com/users/btm/followers","following_url":"https://api.github.com/users/btm/following{/other_user}","gists_url":"https://api.github.com/users/btm/gists{/gist_id}","starred_url":"https://api.github.com/users/btm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btm/subscriptions","organizations_url":"https://api.github.com/users/btm/orgs","repos_url":"https://api.github.com/users/btm/repos","events_url":"https://api.github.com/users/btm/events{/privacy}","received_events_url":"https://api.github.com/users/btm/received_events","type":"User","site_admin":false},"comments":1,"review_comments":0,"commits":4,"additions":18,"deletions":21,"changed_files":3}}