{"action":"created","issue":{"url":"https://api.github.com/repos/eclipse/che/issues/5399","repository_url":"https://api.github.com/repos/eclipse/che","labels_url":"https://api.github.com/repos/eclipse/che/issues/5399/labels{/name}","comments_url":"https://api.github.com/repos/eclipse/che/issues/5399/comments","events_url":"https://api.github.com/repos/eclipse/che/issues/5399/events","html_url":"https://github.com/eclipse/che/pull/5399","id":236814107,"number":5399,"title":"Implement golang bootstrapper","user":{"login":"evoevodin","id":4053805,"avatar_url":"https://avatars1.githubusercontent.com/u/4053805?v=3","gravatar_id":"","url":"https://api.github.com/users/evoevodin","html_url":"https://github.com/evoevodin","followers_url":"https://api.github.com/users/evoevodin/followers","following_url":"https://api.github.com/users/evoevodin/following{/other_user}","gists_url":"https://api.github.com/users/evoevodin/gists{/gist_id}","starred_url":"https://api.github.com/users/evoevodin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evoevodin/subscriptions","organizations_url":"https://api.github.com/users/evoevodin/orgs","repos_url":"https://api.github.com/users/evoevodin/repos","events_url":"https://api.github.com/users/evoevodin/events{/privacy}","received_events_url":"https://api.github.com/users/evoevodin/received_events","type":"User","site_admin":false},"labels":[{"id":583185796,"url":"https://api.github.com/repos/eclipse/che/labels/target/branch","name":"target/branch","color":"0e8a16","default":false}],"state":"open","locked":false,"assignee":{"login":"evoevodin","id":4053805,"avatar_url":"https://avatars1.githubusercontent.com/u/4053805?v=3","gravatar_id":"","url":"https://api.github.com/users/evoevodin","html_url":"https://github.com/evoevodin","followers_url":"https://api.github.com/users/evoevodin/followers","following_url":"https://api.github.com/users/evoevodin/following{/other_user}","gists_url":"https://api.github.com/users/evoevodin/gists{/gist_id}","starred_url":"https://api.github.com/users/evoevodin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evoevodin/subscriptions","organizations_url":"https://api.github.com/users/evoevodin/orgs","repos_url":"https://api.github.com/users/evoevodin/repos","events_url":"https://api.github.com/users/evoevodin/events{/privacy}","received_events_url":"https://api.github.com/users/evoevodin/received_events","type":"User","site_admin":false},"assignees":[{"login":"evoevodin","id":4053805,"avatar_url":"https://avatars1.githubusercontent.com/u/4053805?v=3","gravatar_id":"","url":"https://api.github.com/users/evoevodin","html_url":"https://github.com/evoevodin","followers_url":"https://api.github.com/users/evoevodin/followers","following_url":"https://api.github.com/users/evoevodin/following{/other_user}","gists_url":"https://api.github.com/users/evoevodin/gists{/gist_id}","starred_url":"https://api.github.com/users/evoevodin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evoevodin/subscriptions","organizations_url":"https://api.github.com/users/evoevodin/orgs","repos_url":"https://api.github.com/users/evoevodin/repos","events_url":"https://api.github.com/users/evoevodin/events{/privacy}","received_events_url":"https://api.github.com/users/evoevodin/received_events","type":"User","site_admin":false},{"login":"akorneta","id":12269156,"avatar_url":"https://avatars2.githubusercontent.com/u/12269156?v=3","gravatar_id":"","url":"https://api.github.com/users/akorneta","html_url":"https://github.com/akorneta","followers_url":"https://api.github.com/users/akorneta/followers","following_url":"https://api.github.com/users/akorneta/following{/other_user}","gists_url":"https://api.github.com/users/akorneta/gists{/gist_id}","starred_url":"https://api.github.com/users/akorneta/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akorneta/subscriptions","organizations_url":"https://api.github.com/users/akorneta/orgs","repos_url":"https://api.github.com/users/akorneta/repos","events_url":"https://api.github.com/users/akorneta/events{/privacy}","received_events_url":"https://api.github.com/users/akorneta/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2017-06-19T08:23:41Z","updated_at":"2017-06-19T12:12:25Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/eclipse/che/pulls/5399","html_url":"https://github.com/eclipse/che/pull/5399","diff_url":"https://github.com/eclipse/che/pull/5399.diff","patch_url":"https://github.com/eclipse/che/pull/5399.patch"},"body":"Added golang app which implements bootstrapper [spec(bootstrapper - agents workflow)]( https://github.com/eclipse/che/issues/4096#issuecomment-283067971).\r\n\r\n#### Usage\r\n```\r\nUsage of ./bootstrapper:\r\n  -file string\r\n        Path to configuration file on filesystem (default \"/path/to/binary/location/config.json\")\r\n  -installer-timeout int\r\n        Time(in seconds) given for one installer to complete its installation.\r\n        If installation is not finished in time it will be interrupted (default 120)\r\n  -machine-name string\r\n        The name of the machine in which this bootstrapper is running\r\n  -push-endpoint string\r\n        WebSocket endpoint where to push statuses\r\n  -push-logs-endpoint string\r\n        WebSocket endpoint where to push logs\r\n  -runtime-id string\r\n        The identifier of the runtime in format 'workspace:environment:owner'\r\n  -server-check-period int\r\n        Time(in seconds) between servers availability checks.\r\n        Once servers for one installer available checkers stops (default 3)\r\n```\r\n\r\n#### Example\r\nFor the configuration file\r\n```json\r\n[\r\n  {\r\n    \"id\": \"exec\",\r\n    \"description\": \"Agent for command execution\",\r\n    \"version\": \"1.0\",\r\n    \"script\": \"printf \\\"1\\n2\\n3\\n4\\n5\\n6\\n7\\n8\\n9\\n10\\\"\"\r\n  },\r\n  {\r\n    \"id\": \"agent\",\r\n    \"description\": \"Agent\",\r\n    \"version\": \"1.0\",\r\n    \"script\": \"echo agent-007\"\r\n  },\r\n  {\r\n    \"id\": \"agent-with-server\",\r\n    \"description\": \"this is agent with server\",\r\n    \"version\": \"1.0\",\r\n    \"script\": \"set -e\\ntdir\\u003d$(mktemp -d)\\ncd $tdir\\nAGENT_TAR\\u003dexec-agent-linux_amd64.tar.gz\\nwget http://nightly.codenvy-stg.com/agent-binaries/linux_amd64/exec/${AGENT_TAR}\\ntar -xzf ${AGENT_TAR}\\n./exec-agent/che-exec-agent\\n\",\r\n    \"servers\": {\r\n      \"exec\": {\r\n        \"port\": \"9000/tcp\",\r\n        \"protocol\": \"http\"\r\n      }\r\n    }\r\n  }\r\n]\r\n```\r\nbootstrapper output will be \r\n```\r\n2017/06/19 11:17:00 Bootstrapper configuration\r\n2017/06/19 11:17:00   Push endpoint: ws://localhost:2288/logging-server-connect\r\n2017/06/19 11:17:00   Push logs endpoint: ws://localhost:2288/logging-server-connect\r\n2017/06/19 11:17:00   Runtime ID:\r\n2017/06/19 11:17:00     Workspace: workspace\r\n2017/06/19 11:17:00     Environment: env\r\n2017/06/19 11:17:00     Owner: owner\r\n2017/06/19 11:17:00   Machine name: my-machine\r\n2017/06/19 11:17:00   Installer timeout: 120seconds\r\n2017/06/19 11:17:00   Check servers period: 3seconds\r\n2017/06/19 11:17:00 Planning to install\r\n2017/06/19 11:17:00 - exec:1.0 - Agent for command execution\r\n2017/06/19 11:17:00 - agent:1.0 - Agent\r\n2017/06/19 11:17:00 - agent-with-server:1.0 - this is agent with server\r\n2017/06/19 11:17:00 Starting installations\r\n2017/06/19 11:17:00 Installing 'exec'\r\n2017/06/19 11:17:00 Installation of 'exec' successfully finished\r\n2017/06/19 11:17:00 Installing 'agent'\r\n2017/06/19 11:17:00 Installation of 'agent' successfully finished\r\n2017/06/19 11:17:00 Installing 'agent-with-server'\r\n2017/06/19 11:17:15 Installation of 'agent-with-server' successfully finished\r\n2017/06/19 11:17:15 All installations successfully finished\r\n```\r\n\r\n### What issues does this PR fix or reference?\r\nresolves https://github.com/eclipse/che/issues/4099\r\nspec - https://github.com/eclipse/che/issues/4096#issuecomment-283067971\r\nnew installation approach - https://github.com/eclipse/che/issues/3971\r\n\r\n\r\nPlease note that these changes are going to be merged into SPI branch.\r\n"},"comment":{"url":"https://api.github.com/repos/eclipse/che/issues/comments/309421641","html_url":"https://github.com/eclipse/che/pull/5399#issuecomment-309421641","issue_url":"https://api.github.com/repos/eclipse/che/issues/5399","id":309421641,"user":{"login":"evoevodin","id":4053805,"avatar_url":"https://avatars1.githubusercontent.com/u/4053805?v=3","gravatar_id":"","url":"https://api.github.com/users/evoevodin","html_url":"https://github.com/evoevodin","followers_url":"https://api.github.com/users/evoevodin/followers","following_url":"https://api.github.com/users/evoevodin/following{/other_user}","gists_url":"https://api.github.com/users/evoevodin/gists{/gist_id}","starred_url":"https://api.github.com/users/evoevodin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evoevodin/subscriptions","organizations_url":"https://api.github.com/users/evoevodin/orgs","repos_url":"https://api.github.com/users/evoevodin/repos","events_url":"https://api.github.com/users/evoevodin/events{/privacy}","received_events_url":"https://api.github.com/users/evoevodin/received_events","type":"User","site_admin":false},"created_at":"2017-06-19T12:12:25Z","updated_at":"2017-06-19T12:12:25Z","body":"ok"}}
{"actor":{"display_login":"evoevodin"}}