{"action":"created","comment":{"url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/comments/83568230","pull_request_review_id":4403609,"id":83568230,"diff_hunk":"@@ -0,0 +1,75 @@\n+class eayunstack::upgrade::auto_evacuate::auto_evacuate (\n+  $fuel_settings,\n+) {\n+  $nodes = $fuel_settings['nodes']\n+  $node = filter_nodes($nodes, 'role', 'controller')\n+  $first_node = filter_nodes($nodes, 'role', 'primary-controller')\n+  $storage_ip1 = $first_node[0]['storage_address']\n+  $storage_ip2 = $node[0]['storage_address']\n+  $storage_ip3 = $node[1]['storage_address']\n+  $host_names = [\"${first_node[0]['fqdn']}\", \"${node[0]['fqdn']}\", \"${node[1]['fqdn']}\"]\n+  $host_name = $fuel_settings['fqdn']\n+  $local_ips = filter_nodes($nodes, 'fqdn', $host_name)\n+  $storage_ip = $local_ips[0]['storage_address']\n+  $auth_url = \"http://${fuel_settings['management_vip']}:5000/v2.0\"\n+\n+  $packages = ['consul', 'python-consul', 'eayunstack-auto-evacuate']\n+\n+  $services = ['eayunstack-auto-evacuate', 'consul']\n+\n+  if $eayunstack_node_role == 'controller' {\n+    if $host_name in $host_names {\n+      package { $packages:\n+        ensure => latest,\n+      }\n+\n+      file { 'consul_config_dictory':\n+        ensure  => directory,\n+        path    => \"/etc/consul/storage\",\n+        require => Package['consul']\n+      }\n+\n+      file { 'consul_config_file':\n+        ensure  => file,\n+        path    => \"/etc/consul/storage/consul.json\",\n+        require => File['consul_config_dictory'],\n+        content => template('eayunstack/consul.erb')\n+      }\n+\n+      file { 'consul_exec_dictory':","path":"puppet/modules/eayunstack/manifests/upgrade/auto_evacuate/auto_evacuate.pp","position":39,"original_position":39,"commit_id":"c036cd17044fda9d7c4823b85b46e08dfb4af665","original_commit_id":"c036cd17044fda9d7c4823b85b46e08dfb4af665","user":{"login":"huntxu","id":137809,"avatar_url":"https://avatars.githubusercontent.com/u/137809?v=3","gravatar_id":"","url":"https://api.github.com/users/huntxu","html_url":"https://github.com/huntxu","followers_url":"https://api.github.com/users/huntxu/followers","following_url":"https://api.github.com/users/huntxu/following{/other_user}","gists_url":"https://api.github.com/users/huntxu/gists{/gist_id}","starred_url":"https://api.github.com/users/huntxu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huntxu/subscriptions","organizations_url":"https://api.github.com/users/huntxu/orgs","repos_url":"https://api.github.com/users/huntxu/repos","events_url":"https://api.github.com/users/huntxu/events{/privacy}","received_events_url":"https://api.github.com/users/huntxu/received_events","type":"User","site_admin":false},"body":"这是一个文件，但是命名却是\"dictory\"？还是是一个目录但是内容写错了？","created_at":"2016-10-17T02:00:15Z","updated_at":"2016-10-17T02:05:09Z","html_url":"https://github.com/eayunstack/eayunstack-upgrade/pull/39#discussion_r83568230","pull_request_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39","_links":{"self":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/comments/83568230"},"html":{"href":"https://github.com/eayunstack/eayunstack-upgrade/pull/39#discussion_r83568230"},"pull_request":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39"}}},"pull_request":{"url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39","id":89362251,"html_url":"https://github.com/eayunstack/eayunstack-upgrade/pull/39","diff_url":"https://github.com/eayunstack/eayunstack-upgrade/pull/39.diff","patch_url":"https://github.com/eayunstack/eayunstack-upgrade/pull/39.patch","issue_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/39","number":39,"state":"open","locked":false,"title":"nova: set reclaim instance interval","user":{"login":"fabian4","id":10691174,"avatar_url":"https://avatars.githubusercontent.com/u/10691174?v=3","gravatar_id":"","url":"https://api.github.com/users/fabian4","html_url":"https://github.com/fabian4","followers_url":"https://api.github.com/users/fabian4/followers","following_url":"https://api.github.com/users/fabian4/following{/other_user}","gists_url":"https://api.github.com/users/fabian4/gists{/gist_id}","starred_url":"https://api.github.com/users/fabian4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabian4/subscriptions","organizations_url":"https://api.github.com/users/fabian4/orgs","repos_url":"https://api.github.com/users/fabian4/repos","events_url":"https://api.github.com/users/fabian4/events{/privacy}","received_events_url":"https://api.github.com/users/fabian4/received_events","type":"User","site_admin":false},"body":"      delete reclaim instance only if configure\r\n      update reclaim instance interval time 10 days\r\n\r\nSigned-off-by: apporc <appleorchard2000@gmail.com>\r\n\r\nConflicts:\r\n\tpuppet/modules/eayunstack/manifests/upgrade/nova.pp","created_at":"2016-10-14T10:38:11Z","updated_at":"2016-10-17T02:05:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3a16fee2bd61733989b7f50685b981d008694b0f","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39/commits","review_comments_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39/comments","review_comment_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/comments{/number}","comments_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/39/comments","statuses_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/statuses/c036cd17044fda9d7c4823b85b46e08dfb4af665","head":{"label":"fabian4:soft_delete","ref":"soft_delete","sha":"c036cd17044fda9d7c4823b85b46e08dfb4af665","user":{"login":"fabian4","id":10691174,"avatar_url":"https://avatars.githubusercontent.com/u/10691174?v=3","gravatar_id":"","url":"https://api.github.com/users/fabian4","html_url":"https://github.com/fabian4","followers_url":"https://api.github.com/users/fabian4/followers","following_url":"https://api.github.com/users/fabian4/following{/other_user}","gists_url":"https://api.github.com/users/fabian4/gists{/gist_id}","starred_url":"https://api.github.com/users/fabian4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabian4/subscriptions","organizations_url":"https://api.github.com/users/fabian4/orgs","repos_url":"https://api.github.com/users/fabian4/repos","events_url":"https://api.github.com/users/fabian4/events{/privacy}","received_events_url":"https://api.github.com/users/fabian4/received_events","type":"User","site_admin":false},"repo":{"id":52275469,"name":"eayunstack-upgrade","full_name":"fabian4/eayunstack-upgrade","owner":{"login":"fabian4","id":10691174,"avatar_url":"https://avatars.githubusercontent.com/u/10691174?v=3","gravatar_id":"","url":"https://api.github.com/users/fabian4","html_url":"https://github.com/fabian4","followers_url":"https://api.github.com/users/fabian4/followers","following_url":"https://api.github.com/users/fabian4/following{/other_user}","gists_url":"https://api.github.com/users/fabian4/gists{/gist_id}","starred_url":"https://api.github.com/users/fabian4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabian4/subscriptions","organizations_url":"https://api.github.com/users/fabian4/orgs","repos_url":"https://api.github.com/users/fabian4/repos","events_url":"https://api.github.com/users/fabian4/events{/privacy}","received_events_url":"https://api.github.com/users/fabian4/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/fabian4/eayunstack-upgrade","description":"Puppet bundle for upgrading the whole eayunstack","fork":true,"url":"https://api.github.com/repos/fabian4/eayunstack-upgrade","forks_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/forks","keys_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/teams","hooks_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/hooks","issue_events_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/issues/events{/number}","events_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/events","assignees_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/assignees{/user}","branches_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/branches{/branch}","tags_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/tags","blobs_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/git/refs{/sha}","trees_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/statuses/{sha}","languages_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/languages","stargazers_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/stargazers","contributors_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/contributors","subscribers_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/subscribers","subscription_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/subscription","commits_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/commits{/sha}","git_commits_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/git/commits{/sha}","comments_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/comments{/number}","issue_comment_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/issues/comments{/number}","contents_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/contents/{+path}","compare_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/merges","archive_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/downloads","issues_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/issues{/number}","pulls_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/pulls{/number}","milestones_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/milestones{/number}","notifications_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/labels{/name}","releases_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/releases{/id}","deployments_url":"https://api.github.com/repos/fabian4/eayunstack-upgrade/deployments","created_at":"2016-02-22T13:32:14Z","updated_at":"2016-10-15T14:15:01Z","pushed_at":"2016-10-16T16:33:47Z","git_url":"git://github.com/fabian4/eayunstack-upgrade.git","ssh_url":"git@github.com:fabian4/eayunstack-upgrade.git","clone_url":"https://github.com/fabian4/eayunstack-upgrade.git","svn_url":"https://github.com/fabian4/eayunstack-upgrade","homepage":null,"size":65,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"eayunstack:master","ref":"master","sha":"793b4e6c56c2b452bb3f0d66d9696494f43e11cc","user":{"login":"eayunstack","id":8656371,"avatar_url":"https://avatars.githubusercontent.com/u/8656371?v=3","gravatar_id":"","url":"https://api.github.com/users/eayunstack","html_url":"https://github.com/eayunstack","followers_url":"https://api.github.com/users/eayunstack/followers","following_url":"https://api.github.com/users/eayunstack/following{/other_user}","gists_url":"https://api.github.com/users/eayunstack/gists{/gist_id}","starred_url":"https://api.github.com/users/eayunstack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eayunstack/subscriptions","organizations_url":"https://api.github.com/users/eayunstack/orgs","repos_url":"https://api.github.com/users/eayunstack/repos","events_url":"https://api.github.com/users/eayunstack/events{/privacy}","received_events_url":"https://api.github.com/users/eayunstack/received_events","type":"Organization","site_admin":false},"repo":{"id":48354515,"name":"eayunstack-upgrade","full_name":"eayunstack/eayunstack-upgrade","owner":{"login":"eayunstack","id":8656371,"avatar_url":"https://avatars.githubusercontent.com/u/8656371?v=3","gravatar_id":"","url":"https://api.github.com/users/eayunstack","html_url":"https://github.com/eayunstack","followers_url":"https://api.github.com/users/eayunstack/followers","following_url":"https://api.github.com/users/eayunstack/following{/other_user}","gists_url":"https://api.github.com/users/eayunstack/gists{/gist_id}","starred_url":"https://api.github.com/users/eayunstack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eayunstack/subscriptions","organizations_url":"https://api.github.com/users/eayunstack/orgs","repos_url":"https://api.github.com/users/eayunstack/repos","events_url":"https://api.github.com/users/eayunstack/events{/privacy}","received_events_url":"https://api.github.com/users/eayunstack/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/eayunstack/eayunstack-upgrade","description":"Puppet bundle for upgrading the whole eayunstack","fork":false,"url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade","forks_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/forks","keys_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/teams","hooks_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/hooks","issue_events_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/events{/number}","events_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/events","assignees_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/assignees{/user}","branches_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/branches{/branch}","tags_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/tags","blobs_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/git/refs{/sha}","trees_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/statuses/{sha}","languages_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/languages","stargazers_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/stargazers","contributors_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/contributors","subscribers_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/subscribers","subscription_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/subscription","commits_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/commits{/sha}","git_commits_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/git/commits{/sha}","comments_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/comments{/number}","issue_comment_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/comments{/number}","contents_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/contents/{+path}","compare_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/merges","archive_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/downloads","issues_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues{/number}","pulls_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls{/number}","milestones_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/milestones{/number}","notifications_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/labels{/name}","releases_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/releases{/id}","deployments_url":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/deployments","created_at":"2015-12-21T06:19:37Z","updated_at":"2016-08-08T10:32:20Z","pushed_at":"2016-10-16T16:33:47Z","git_url":"git://github.com/eayunstack/eayunstack-upgrade.git","ssh_url":"git@github.com:eayunstack/eayunstack-upgrade.git","clone_url":"https://github.com/eayunstack/eayunstack-upgrade.git","svn_url":"https://github.com/eayunstack/eayunstack-upgrade","homepage":null,"size":129,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":2,"forks":7,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39"},"html":{"href":"https://github.com/eayunstack/eayunstack-upgrade/pull/39"},"issue":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/39"},"comments":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/issues/39/comments"},"review_comments":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39/comments"},"review_comment":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/pulls/39/commits"},"statuses":{"href":"https://api.github.com/repos/eayunstack/eayunstack-upgrade/statuses/c036cd17044fda9d7c4823b85b46e08dfb4af665"}}}}
{"actor":{"display_login":"huntxu"}}