{"action":"created","comment":{"url":"https://api.github.com/repos/supergiant/supergiant/pulls/comments/194086113","pull_request_review_id":127197803,"id":194086113,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5NDA4NjExMw==","diff_hunk":"@@ -0,0 +1,106 @@\n+package ssh\n+\n+import (\n+\t\"context\"\n+\t\"errors\"\n+\t\"fmt\"\n+\t\"io\"\n+\t\"os\"\n+\n+\t\"golang.org/x/crypto/ssh\"\n+\n+\t\"github.com/ayufan/gitlab-ci-multi-runner/helpers\"\n+\n+\t\"github.com/supergiant/supergiant/pkg/runner/command\"\n+)\n+\n+// Config is a set of params needed to create valid ssh.ClientConfig\n+type Config struct {\n+\tHost    string\n+\tPort    int\n+\tUser    string\n+\tTimeout int\n+\n+\tKeyFilePath string\n+\n+\tSshClientConfig *ssh.ClientConfig\n+}\n+\n+// Runner is implementation of runner interface for ssh\n+type Runner struct {\n+\t*Config\n+\tout io.Writer\n+\terr io.Writer\n+\n+\tclient *ssh.Client\n+}\n+\n+// NewRunner creates ssh runner object. It requires two io.Writer\n+// to send output of ssh session and config for ssh client.\n+func NewRunner(out, err io.Writer, config *Config) (*Runner, error) {","path":"pkg/runner/ssh/runner.go","position":40,"original_position":40,"commit_id":"db845f925aeef19af57b65ac8659063907180d1b","original_commit_id":"db845f925aeef19af57b65ac8659063907180d1b","user":{"login":"saheienko","id":26225544,"node_id":"MDQ6VXNlcjI2MjI1NTQ0","avatar_url":"https://avatars2.githubusercontent.com/u/26225544?v=4","gravatar_id":"","url":"https://api.github.com/users/saheienko","html_url":"https://github.com/saheienko","followers_url":"https://api.github.com/users/saheienko/followers","following_url":"https://api.github.com/users/saheienko/following{/other_user}","gists_url":"https://api.github.com/users/saheienko/gists{/gist_id}","starred_url":"https://api.github.com/users/saheienko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saheienko/subscriptions","organizations_url":"https://api.github.com/users/saheienko/orgs","repos_url":"https://api.github.com/users/saheienko/repos","events_url":"https://api.github.com/users/saheienko/events{/privacy}","received_events_url":"https://api.github.com/users/saheienko/received_events","type":"User","site_admin":false},"body":"Yes, in case if you receive out/err writers for every command.","created_at":"2018-06-08T15:00:56Z","updated_at":"2018-06-08T15:00:57Z","html_url":"https://github.com/supergiant/supergiant/pull/517#discussion_r194086113","pull_request_url":"https://api.github.com/repos/supergiant/supergiant/pulls/517","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/comments/194086113"},"html":{"href":"https://github.com/supergiant/supergiant/pull/517#discussion_r194086113"},"pull_request":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/517"}},"in_reply_to_id":194071820},"pull_request":{"url":"https://api.github.com/repos/supergiant/supergiant/pulls/517","id":193072518,"node_id":"MDExOlB1bGxSZXF1ZXN0MTkzMDcyNTE4","html_url":"https://github.com/supergiant/supergiant/pull/517","diff_url":"https://github.com/supergiant/supergiant/pull/517.diff","patch_url":"https://github.com/supergiant/supergiant/pull/517.patch","issue_url":"https://api.github.com/repos/supergiant/supergiant/issues/517","number":517,"state":"open","locked":false,"title":"Add ssh and shell runners","user":{"login":"stgleb","id":5112367,"node_id":"MDQ6VXNlcjUxMTIzNjc=","avatar_url":"https://avatars1.githubusercontent.com/u/5112367?v=4","gravatar_id":"","url":"https://api.github.com/users/stgleb","html_url":"https://github.com/stgleb","followers_url":"https://api.github.com/users/stgleb/followers","following_url":"https://api.github.com/users/stgleb/following{/other_user}","gists_url":"https://api.github.com/users/stgleb/gists{/gist_id}","starred_url":"https://api.github.com/users/stgleb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgleb/subscriptions","organizations_url":"https://api.github.com/users/stgleb/orgs","repos_url":"https://api.github.com/users/stgleb/repos","events_url":"https://api.github.com/users/stgleb/events{/privacy}","received_events_url":"https://api.github.com/users/stgleb/received_events","type":"User","site_admin":false},"body":"Runner is an entity intended to run abstract commands in different environments.","created_at":"2018-06-06T16:32:41Z","updated_at":"2018-06-08T15:00:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"83dee5a654825927bc7b42f6dae4600c7c3fc7b3","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/supergiant/supergiant/pulls/517/commits","review_comments_url":"https://api.github.com/repos/supergiant/supergiant/pulls/517/comments","review_comment_url":"https://api.github.com/repos/supergiant/supergiant/pulls/comments{/number}","comments_url":"https://api.github.com/repos/supergiant/supergiant/issues/517/comments","statuses_url":"https://api.github.com/repos/supergiant/supergiant/statuses/db845f925aeef19af57b65ac8659063907180d1b","head":{"label":"stgleb:runner","ref":"runner","sha":"db845f925aeef19af57b65ac8659063907180d1b","user":{"login":"stgleb","id":5112367,"node_id":"MDQ6VXNlcjUxMTIzNjc=","avatar_url":"https://avatars1.githubusercontent.com/u/5112367?v=4","gravatar_id":"","url":"https://api.github.com/users/stgleb","html_url":"https://github.com/stgleb","followers_url":"https://api.github.com/users/stgleb/followers","following_url":"https://api.github.com/users/stgleb/following{/other_user}","gists_url":"https://api.github.com/users/stgleb/gists{/gist_id}","starred_url":"https://api.github.com/users/stgleb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgleb/subscriptions","organizations_url":"https://api.github.com/users/stgleb/orgs","repos_url":"https://api.github.com/users/stgleb/repos","events_url":"https://api.github.com/users/stgleb/events{/privacy}","received_events_url":"https://api.github.com/users/stgleb/received_events","type":"User","site_admin":false},"repo":{"id":132445628,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI0NDU2Mjg=","name":"supergiant","full_name":"stgleb/supergiant","owner":{"login":"stgleb","id":5112367,"node_id":"MDQ6VXNlcjUxMTIzNjc=","avatar_url":"https://avatars1.githubusercontent.com/u/5112367?v=4","gravatar_id":"","url":"https://api.github.com/users/stgleb","html_url":"https://github.com/stgleb","followers_url":"https://api.github.com/users/stgleb/followers","following_url":"https://api.github.com/users/stgleb/following{/other_user}","gists_url":"https://api.github.com/users/stgleb/gists{/gist_id}","starred_url":"https://api.github.com/users/stgleb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgleb/subscriptions","organizations_url":"https://api.github.com/users/stgleb/orgs","repos_url":"https://api.github.com/users/stgleb/repos","events_url":"https://api.github.com/users/stgleb/events{/privacy}","received_events_url":"https://api.github.com/users/stgleb/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/stgleb/supergiant","description":"Automatically scale hardware and easily run stateful applications using Kubernetes.","fork":true,"url":"https://api.github.com/repos/stgleb/supergiant","forks_url":"https://api.github.com/repos/stgleb/supergiant/forks","keys_url":"https://api.github.com/repos/stgleb/supergiant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stgleb/supergiant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stgleb/supergiant/teams","hooks_url":"https://api.github.com/repos/stgleb/supergiant/hooks","issue_events_url":"https://api.github.com/repos/stgleb/supergiant/issues/events{/number}","events_url":"https://api.github.com/repos/stgleb/supergiant/events","assignees_url":"https://api.github.com/repos/stgleb/supergiant/assignees{/user}","branches_url":"https://api.github.com/repos/stgleb/supergiant/branches{/branch}","tags_url":"https://api.github.com/repos/stgleb/supergiant/tags","blobs_url":"https://api.github.com/repos/stgleb/supergiant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stgleb/supergiant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stgleb/supergiant/git/refs{/sha}","trees_url":"https://api.github.com/repos/stgleb/supergiant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stgleb/supergiant/statuses/{sha}","languages_url":"https://api.github.com/repos/stgleb/supergiant/languages","stargazers_url":"https://api.github.com/repos/stgleb/supergiant/stargazers","contributors_url":"https://api.github.com/repos/stgleb/supergiant/contributors","subscribers_url":"https://api.github.com/repos/stgleb/supergiant/subscribers","subscription_url":"https://api.github.com/repos/stgleb/supergiant/subscription","commits_url":"https://api.github.com/repos/stgleb/supergiant/commits{/sha}","git_commits_url":"https://api.github.com/repos/stgleb/supergiant/git/commits{/sha}","comments_url":"https://api.github.com/repos/stgleb/supergiant/comments{/number}","issue_comment_url":"https://api.github.com/repos/stgleb/supergiant/issues/comments{/number}","contents_url":"https://api.github.com/repos/stgleb/supergiant/contents/{+path}","compare_url":"https://api.github.com/repos/stgleb/supergiant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stgleb/supergiant/merges","archive_url":"https://api.github.com/repos/stgleb/supergiant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stgleb/supergiant/downloads","issues_url":"https://api.github.com/repos/stgleb/supergiant/issues{/number}","pulls_url":"https://api.github.com/repos/stgleb/supergiant/pulls{/number}","milestones_url":"https://api.github.com/repos/stgleb/supergiant/milestones{/number}","notifications_url":"https://api.github.com/repos/stgleb/supergiant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stgleb/supergiant/labels{/name}","releases_url":"https://api.github.com/repos/stgleb/supergiant/releases{/id}","deployments_url":"https://api.github.com/repos/stgleb/supergiant/deployments","created_at":"2018-05-07T10:35:48Z","updated_at":"2018-06-01T10:17:30Z","pushed_at":"2018-06-08T13:36:44Z","git_url":"git://github.com/stgleb/supergiant.git","ssh_url":"git@github.com:stgleb/supergiant.git","clone_url":"https://github.com/stgleb/supergiant.git","svn_url":"https://github.com/stgleb/supergiant","homepage":"https://supergiant.io/","size":11943,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"supergiant:master","ref":"master","sha":"c5c6a8cad852627a1466b3a34243fadf250ff5e6","user":{"login":"supergiant","id":17504253,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3NTA0MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/17504253?v=4","gravatar_id":"","url":"https://api.github.com/users/supergiant","html_url":"https://github.com/supergiant","followers_url":"https://api.github.com/users/supergiant/followers","following_url":"https://api.github.com/users/supergiant/following{/other_user}","gists_url":"https://api.github.com/users/supergiant/gists{/gist_id}","starred_url":"https://api.github.com/users/supergiant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/supergiant/subscriptions","organizations_url":"https://api.github.com/users/supergiant/orgs","repos_url":"https://api.github.com/users/supergiant/repos","events_url":"https://api.github.com/users/supergiant/events{/privacy}","received_events_url":"https://api.github.com/users/supergiant/received_events","type":"Organization","site_admin":false},"repo":{"id":52634092,"node_id":"MDEwOlJlcG9zaXRvcnk1MjYzNDA5Mg==","name":"supergiant","full_name":"supergiant/supergiant","owner":{"login":"supergiant","id":17504253,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3NTA0MjUz","avatar_url":"https://avatars0.githubusercontent.com/u/17504253?v=4","gravatar_id":"","url":"https://api.github.com/users/supergiant","html_url":"https://github.com/supergiant","followers_url":"https://api.github.com/users/supergiant/followers","following_url":"https://api.github.com/users/supergiant/following{/other_user}","gists_url":"https://api.github.com/users/supergiant/gists{/gist_id}","starred_url":"https://api.github.com/users/supergiant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/supergiant/subscriptions","organizations_url":"https://api.github.com/users/supergiant/orgs","repos_url":"https://api.github.com/users/supergiant/repos","events_url":"https://api.github.com/users/supergiant/events{/privacy}","received_events_url":"https://api.github.com/users/supergiant/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/supergiant/supergiant","description":"Automatically scale hardware and easily run stateful applications using Kubernetes.","fork":false,"url":"https://api.github.com/repos/supergiant/supergiant","forks_url":"https://api.github.com/repos/supergiant/supergiant/forks","keys_url":"https://api.github.com/repos/supergiant/supergiant/keys{/key_id}","collaborators_url":"https://api.github.com/repos/supergiant/supergiant/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/supergiant/supergiant/teams","hooks_url":"https://api.github.com/repos/supergiant/supergiant/hooks","issue_events_url":"https://api.github.com/repos/supergiant/supergiant/issues/events{/number}","events_url":"https://api.github.com/repos/supergiant/supergiant/events","assignees_url":"https://api.github.com/repos/supergiant/supergiant/assignees{/user}","branches_url":"https://api.github.com/repos/supergiant/supergiant/branches{/branch}","tags_url":"https://api.github.com/repos/supergiant/supergiant/tags","blobs_url":"https://api.github.com/repos/supergiant/supergiant/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/supergiant/supergiant/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/supergiant/supergiant/git/refs{/sha}","trees_url":"https://api.github.com/repos/supergiant/supergiant/git/trees{/sha}","statuses_url":"https://api.github.com/repos/supergiant/supergiant/statuses/{sha}","languages_url":"https://api.github.com/repos/supergiant/supergiant/languages","stargazers_url":"https://api.github.com/repos/supergiant/supergiant/stargazers","contributors_url":"https://api.github.com/repos/supergiant/supergiant/contributors","subscribers_url":"https://api.github.com/repos/supergiant/supergiant/subscribers","subscription_url":"https://api.github.com/repos/supergiant/supergiant/subscription","commits_url":"https://api.github.com/repos/supergiant/supergiant/commits{/sha}","git_commits_url":"https://api.github.com/repos/supergiant/supergiant/git/commits{/sha}","comments_url":"https://api.github.com/repos/supergiant/supergiant/comments{/number}","issue_comment_url":"https://api.github.com/repos/supergiant/supergiant/issues/comments{/number}","contents_url":"https://api.github.com/repos/supergiant/supergiant/contents/{+path}","compare_url":"https://api.github.com/repos/supergiant/supergiant/compare/{base}...{head}","merges_url":"https://api.github.com/repos/supergiant/supergiant/merges","archive_url":"https://api.github.com/repos/supergiant/supergiant/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/supergiant/supergiant/downloads","issues_url":"https://api.github.com/repos/supergiant/supergiant/issues{/number}","pulls_url":"https://api.github.com/repos/supergiant/supergiant/pulls{/number}","milestones_url":"https://api.github.com/repos/supergiant/supergiant/milestones{/number}","notifications_url":"https://api.github.com/repos/supergiant/supergiant/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/supergiant/supergiant/labels{/name}","releases_url":"https://api.github.com/repos/supergiant/supergiant/releases{/id}","deployments_url":"https://api.github.com/repos/supergiant/supergiant/deployments","created_at":"2016-02-26T21:32:33Z","updated_at":"2018-06-05T21:19:55Z","pushed_at":"2018-06-08T13:57:02Z","git_url":"git://github.com/supergiant/supergiant.git","ssh_url":"git@github.com:supergiant/supergiant.git","clone_url":"https://github.com/supergiant/supergiant.git","svn_url":"https://github.com/supergiant/supergiant","homepage":"https://supergiant.io/","size":11766,"stargazers_count":564,"watchers_count":564,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":49,"mirror_url":null,"archived":false,"open_issues_count":45,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":49,"open_issues":45,"watchers":564,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/517"},"html":{"href":"https://github.com/supergiant/supergiant/pull/517"},"issue":{"href":"https://api.github.com/repos/supergiant/supergiant/issues/517"},"comments":{"href":"https://api.github.com/repos/supergiant/supergiant/issues/517/comments"},"review_comments":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/517/comments"},"review_comment":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/supergiant/supergiant/pulls/517/commits"},"statuses":{"href":"https://api.github.com/repos/supergiant/supergiant/statuses/db845f925aeef19af57b65ac8659063907180d1b"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"saheienko"}}