{"action":"created","comment":{"url":"https://api.github.com/repos/google/cadvisor/pulls/comments/52688331","id":52688331,"diff_hunk":"@@ -78,23 +78,29 @@ func RunCommand(cmd string, args ...string) error {\n \treturn nil\n }\n \n+func RunSshCommand(cmd string, args ...string) error {\n+\tif *sshOptions != \"\" {\n+\t\targs = append(strings.Split(*sshOptions, \" \"), args...)\n+\t}\n+\treturn RunCommand(cmd, args...)\n+}\n+\n func PushAndRunTests(host, testDir string) error {\n \t// Push binary.\n \tglog.Infof(\"Pushing cAdvisor binary to %q...\", host)\n-\targs := common.GetGCComputeArgs(\"ssh\", host, \"--\", \"mkdir\", \"-p\", testDir)\n-\terr := RunCommand(\"gcloud\", args...)\n+\n+\terr := RunSshCommand(\"ssh\", host, \"--\", \"mkdir\", \"-p\", testDir)\n \tif err != nil {\n \t\treturn fmt.Errorf(\"failed to make remote testing directory: %v\", err)\n \t}\n \tdefer func() {\n-\t\targs := common.GetGCComputeArgs(\"ssh\", host, \"--\", \"rm\", \"-rf\", testDir)\n-\t\terr := RunCommand(\"gcloud\", args...)\n+\t\terr = RunSshCommand(\"ssh\", host, \"--\", \"rm\", \"-rf\", testDir)\n \t\tif err != nil {\n \t\t\tglog.Errorf(\"Failed to cleanup test directory: %v\", err)\n \t\t}\n \t}()\n-\targs = common.GetGCComputeArgs(\"copy-files\", cadvisorBinary, fmt.Sprintf(\"%s:%s\", host, testDir))\n-\terr = RunCommand(\"gcloud\", args...)\n+\n+\terr = RunSshCommand(\"scp\", \"-r\", cadvisorBinary, fmt.Sprintf(\"%s:%s\", host, testDir))","path":"integration/runner/runner.go","position":58,"original_position":58,"commit_id":"84738b9226c36bbc301898855cf574d13839dfe6","original_commit_id":"84738b9226c36bbc301898855cf574d13839dfe6","user":{"login":"timstclair","id":3272040,"avatar_url":"https://avatars.githubusercontent.com/u/3272040?v=3","gravatar_id":"","url":"https://api.github.com/users/timstclair","html_url":"https://github.com/timstclair","followers_url":"https://api.github.com/users/timstclair/followers","following_url":"https://api.github.com/users/timstclair/following{/other_user}","gists_url":"https://api.github.com/users/timstclair/gists{/gist_id}","starred_url":"https://api.github.com/users/timstclair/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timstclair/subscriptions","organizations_url":"https://api.github.com/users/timstclair/orgs","repos_url":"https://api.github.com/users/timstclair/repos","events_url":"https://api.github.com/users/timstclair/events{/privacy}","received_events_url":"https://api.github.com/users/timstclair/received_events","type":"User","site_admin":false},"body":"If you do that, you could drop the `cmd` argument in `RunSshCommand`, and just always use the 'ssh' command. ","created_at":"2016-02-12T00:01:12Z","updated_at":"2016-02-12T00:01:12Z","html_url":"https://github.com/google/cadvisor/pull/1108#discussion_r52688331","pull_request_url":"https://api.github.com/repos/google/cadvisor/pulls/1108","_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments/52688331"},"html":{"href":"https://github.com/google/cadvisor/pull/1108#discussion_r52688331"},"pull_request":{"href":"https://api.github.com/repos/google/cadvisor/pulls/1108"}}},"pull_request":{"url":"https://api.github.com/repos/google/cadvisor/pulls/1108","id":58980790,"html_url":"https://github.com/google/cadvisor/pull/1108","diff_url":"https://github.com/google/cadvisor/pull/1108.diff","patch_url":"https://github.com/google/cadvisor/pull/1108.patch","issue_url":"https://api.github.com/repos/google/cadvisor/issues/1108","number":1108,"state":"open","locked":false,"title":"Use vanilla ssh instead of gcloud ssh for e2e tests","user":{"login":"pwittrock","id":7882754,"avatar_url":"https://avatars.githubusercontent.com/u/7882754?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittrock","html_url":"https://github.com/pwittrock","followers_url":"https://api.github.com/users/pwittrock/followers","following_url":"https://api.github.com/users/pwittrock/following{/other_user}","gists_url":"https://api.github.com/users/pwittrock/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittrock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittrock/subscriptions","organizations_url":"https://api.github.com/users/pwittrock/orgs","repos_url":"https://api.github.com/users/pwittrock/repos","events_url":"https://api.github.com/users/pwittrock/events{/privacy}","received_events_url":"https://api.github.com/users/pwittrock/received_events","type":"User","site_admin":false},"body":"This is a proof of concept to get away from gcloud compute, which seems to cause a lot of flakes in the PR builder, and instead use ssh/scp directly with an ssh_config file.\r\n\r\nDoes this seem like the correct way to more forward.\r\n\r\nTIP: You can generate a config file for gce machines using `gcloud compute config-ssh --dry-run`","created_at":"2016-02-11T01:14:09Z","updated_at":"2016-02-12T00:01:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"db4e367cda42d2e44494e75a298849515251182c","assignee":{"login":"timstclair","id":3272040,"avatar_url":"https://avatars.githubusercontent.com/u/3272040?v=3","gravatar_id":"","url":"https://api.github.com/users/timstclair","html_url":"https://github.com/timstclair","followers_url":"https://api.github.com/users/timstclair/followers","following_url":"https://api.github.com/users/timstclair/following{/other_user}","gists_url":"https://api.github.com/users/timstclair/gists{/gist_id}","starred_url":"https://api.github.com/users/timstclair/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timstclair/subscriptions","organizations_url":"https://api.github.com/users/timstclair/orgs","repos_url":"https://api.github.com/users/timstclair/repos","events_url":"https://api.github.com/users/timstclair/events{/privacy}","received_events_url":"https://api.github.com/users/timstclair/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/google/cadvisor/pulls/1108/commits","review_comments_url":"https://api.github.com/repos/google/cadvisor/pulls/1108/comments","review_comment_url":"https://api.github.com/repos/google/cadvisor/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/cadvisor/issues/1108/comments","statuses_url":"https://api.github.com/repos/google/cadvisor/statuses/84738b9226c36bbc301898855cf574d13839dfe6","head":{"label":"pwittrock:integration-test-use-direct-ssh","ref":"integration-test-use-direct-ssh","sha":"84738b9226c36bbc301898855cf574d13839dfe6","user":{"login":"pwittrock","id":7882754,"avatar_url":"https://avatars.githubusercontent.com/u/7882754?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittrock","html_url":"https://github.com/pwittrock","followers_url":"https://api.github.com/users/pwittrock/followers","following_url":"https://api.github.com/users/pwittrock/following{/other_user}","gists_url":"https://api.github.com/users/pwittrock/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittrock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittrock/subscriptions","organizations_url":"https://api.github.com/users/pwittrock/orgs","repos_url":"https://api.github.com/users/pwittrock/repos","events_url":"https://api.github.com/users/pwittrock/events{/privacy}","received_events_url":"https://api.github.com/users/pwittrock/received_events","type":"User","site_admin":false},"repo":{"id":41059807,"name":"cadvisor","full_name":"pwittrock/cadvisor","owner":{"login":"pwittrock","id":7882754,"avatar_url":"https://avatars.githubusercontent.com/u/7882754?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittrock","html_url":"https://github.com/pwittrock","followers_url":"https://api.github.com/users/pwittrock/followers","following_url":"https://api.github.com/users/pwittrock/following{/other_user}","gists_url":"https://api.github.com/users/pwittrock/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittrock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittrock/subscriptions","organizations_url":"https://api.github.com/users/pwittrock/orgs","repos_url":"https://api.github.com/users/pwittrock/repos","events_url":"https://api.github.com/users/pwittrock/events{/privacy}","received_events_url":"https://api.github.com/users/pwittrock/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pwittrock/cadvisor","description":"Analyzes resource usage and performance characteristics of running containers.","fork":true,"url":"https://api.github.com/repos/pwittrock/cadvisor","forks_url":"https://api.github.com/repos/pwittrock/cadvisor/forks","keys_url":"https://api.github.com/repos/pwittrock/cadvisor/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pwittrock/cadvisor/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pwittrock/cadvisor/teams","hooks_url":"https://api.github.com/repos/pwittrock/cadvisor/hooks","issue_events_url":"https://api.github.com/repos/pwittrock/cadvisor/issues/events{/number}","events_url":"https://api.github.com/repos/pwittrock/cadvisor/events","assignees_url":"https://api.github.com/repos/pwittrock/cadvisor/assignees{/user}","branches_url":"https://api.github.com/repos/pwittrock/cadvisor/branches{/branch}","tags_url":"https://api.github.com/repos/pwittrock/cadvisor/tags","blobs_url":"https://api.github.com/repos/pwittrock/cadvisor/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pwittrock/cadvisor/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pwittrock/cadvisor/git/refs{/sha}","trees_url":"https://api.github.com/repos/pwittrock/cadvisor/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pwittrock/cadvisor/statuses/{sha}","languages_url":"https://api.github.com/repos/pwittrock/cadvisor/languages","stargazers_url":"https://api.github.com/repos/pwittrock/cadvisor/stargazers","contributors_url":"https://api.github.com/repos/pwittrock/cadvisor/contributors","subscribers_url":"https://api.github.com/repos/pwittrock/cadvisor/subscribers","subscription_url":"https://api.github.com/repos/pwittrock/cadvisor/subscription","commits_url":"https://api.github.com/repos/pwittrock/cadvisor/commits{/sha}","git_commits_url":"https://api.github.com/repos/pwittrock/cadvisor/git/commits{/sha}","comments_url":"https://api.github.com/repos/pwittrock/cadvisor/comments{/number}","issue_comment_url":"https://api.github.com/repos/pwittrock/cadvisor/issues/comments{/number}","contents_url":"https://api.github.com/repos/pwittrock/cadvisor/contents/{+path}","compare_url":"https://api.github.com/repos/pwittrock/cadvisor/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pwittrock/cadvisor/merges","archive_url":"https://api.github.com/repos/pwittrock/cadvisor/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pwittrock/cadvisor/downloads","issues_url":"https://api.github.com/repos/pwittrock/cadvisor/issues{/number}","pulls_url":"https://api.github.com/repos/pwittrock/cadvisor/pulls{/number}","milestones_url":"https://api.github.com/repos/pwittrock/cadvisor/milestones{/number}","notifications_url":"https://api.github.com/repos/pwittrock/cadvisor/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pwittrock/cadvisor/labels{/name}","releases_url":"https://api.github.com/repos/pwittrock/cadvisor/releases{/id}","deployments_url":"https://api.github.com/repos/pwittrock/cadvisor/deployments","created_at":"2015-08-19T21:05:45Z","updated_at":"2016-01-15T00:53:10Z","pushed_at":"2016-02-11T23:24:59Z","git_url":"git://github.com/pwittrock/cadvisor.git","ssh_url":"git@github.com:pwittrock/cadvisor.git","clone_url":"https://github.com/pwittrock/cadvisor.git","svn_url":"https://github.com/pwittrock/cadvisor","homepage":"","size":19570,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"google:master","ref":"master","sha":"94cef953b172bfc43ff3c4580b69028ada0d0879","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":20653934,"name":"cadvisor","full_name":"google/cadvisor","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/cadvisor","description":"Analyzes resource usage and performance characteristics of running containers.","fork":false,"url":"https://api.github.com/repos/google/cadvisor","forks_url":"https://api.github.com/repos/google/cadvisor/forks","keys_url":"https://api.github.com/repos/google/cadvisor/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/cadvisor/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/cadvisor/teams","hooks_url":"https://api.github.com/repos/google/cadvisor/hooks","issue_events_url":"https://api.github.com/repos/google/cadvisor/issues/events{/number}","events_url":"https://api.github.com/repos/google/cadvisor/events","assignees_url":"https://api.github.com/repos/google/cadvisor/assignees{/user}","branches_url":"https://api.github.com/repos/google/cadvisor/branches{/branch}","tags_url":"https://api.github.com/repos/google/cadvisor/tags","blobs_url":"https://api.github.com/repos/google/cadvisor/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/cadvisor/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/cadvisor/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/cadvisor/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/cadvisor/statuses/{sha}","languages_url":"https://api.github.com/repos/google/cadvisor/languages","stargazers_url":"https://api.github.com/repos/google/cadvisor/stargazers","contributors_url":"https://api.github.com/repos/google/cadvisor/contributors","subscribers_url":"https://api.github.com/repos/google/cadvisor/subscribers","subscription_url":"https://api.github.com/repos/google/cadvisor/subscription","commits_url":"https://api.github.com/repos/google/cadvisor/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/cadvisor/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/cadvisor/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/cadvisor/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/cadvisor/contents/{+path}","compare_url":"https://api.github.com/repos/google/cadvisor/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/cadvisor/merges","archive_url":"https://api.github.com/repos/google/cadvisor/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/cadvisor/downloads","issues_url":"https://api.github.com/repos/google/cadvisor/issues{/number}","pulls_url":"https://api.github.com/repos/google/cadvisor/pulls{/number}","milestones_url":"https://api.github.com/repos/google/cadvisor/milestones{/number}","notifications_url":"https://api.github.com/repos/google/cadvisor/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/cadvisor/labels{/name}","releases_url":"https://api.github.com/repos/google/cadvisor/releases{/id}","deployments_url":"https://api.github.com/repos/google/cadvisor/deployments","created_at":"2014-06-09T16:36:33Z","updated_at":"2016-02-11T21:47:03Z","pushed_at":"2016-02-11T23:27:18Z","git_url":"git://github.com/google/cadvisor.git","ssh_url":"git@github.com:google/cadvisor.git","clone_url":"https://github.com/google/cadvisor.git","svn_url":"https://github.com/google/cadvisor","homepage":"","size":24186,"stargazers_count":3521,"watchers_count":3521,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":463,"mirror_url":null,"open_issues_count":122,"forks":463,"open_issues":122,"watchers":3521,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/1108"},"html":{"href":"https://github.com/google/cadvisor/pull/1108"},"issue":{"href":"https://api.github.com/repos/google/cadvisor/issues/1108"},"comments":{"href":"https://api.github.com/repos/google/cadvisor/issues/1108/comments"},"review_comments":{"href":"https://api.github.com/repos/google/cadvisor/pulls/1108/comments"},"review_comment":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/cadvisor/pulls/1108/commits"},"statuses":{"href":"https://api.github.com/repos/google/cadvisor/statuses/84738b9226c36bbc301898855cf574d13839dfe6"}}}}