{"action":"created","comment":{"url":"https://api.github.com/repos/ceph/ceph-docker/pulls/comments/104968111","pull_request_review_id":25826169,"id":104968111,"diff_hunk":"@@ -154,3 +154,31 @@ function is_integer {\n function to_lowercase {\n   echo \"${@,,}\"\n }\n+\n+child_for_exec=1\n+_term() {\n+  log \"Sending SIGTERM to PID $child_for_exec\"\n+\n+  # disabling the ERR trap before killing the process\n+  # That's an expected failure so don't handle it\n+  trap ERR\n+  NOTRAP=\"yes\"\n+\n+  kill -TERM \"$child_for_exec\" 2>/dev/null\n+}\n+\n+do_exec() {\n+  # This function do the same kind of behavior as exec","path":"ceph-releases/kraken/ubuntu/16.04/daemon/common_functions.sh","position":18,"original_position":18,"commit_id":"c61e9093dabd9f3cbeb9d8a28299b301ff2b09fc","original_commit_id":"c1b12d2011a6ee843b3ac8ee0985b82355ccaeb8","user":{"login":"leseb","id":912735,"avatar_url":"https://avatars0.githubusercontent.com/u/912735?v=3","gravatar_id":"","url":"https://api.github.com/users/leseb","html_url":"https://github.com/leseb","followers_url":"https://api.github.com/users/leseb/followers","following_url":"https://api.github.com/users/leseb/following{/other_user}","gists_url":"https://api.github.com/users/leseb/gists{/gist_id}","starred_url":"https://api.github.com/users/leseb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leseb/subscriptions","organizations_url":"https://api.github.com/users/leseb/orgs","repos_url":"https://api.github.com/users/leseb/repos","events_url":"https://api.github.com/users/leseb/events{/privacy}","received_events_url":"https://api.github.com/users/leseb/received_events","type":"User","site_admin":false},"body":"s/do/does/","created_at":"2017-03-08T17:06:43Z","updated_at":"2017-03-08T17:07:23Z","html_url":"https://github.com/ceph/ceph-docker/pull/532#discussion_r104968111","pull_request_url":"https://api.github.com/repos/ceph/ceph-docker/pulls/532","_links":{"self":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/comments/104968111"},"html":{"href":"https://github.com/ceph/ceph-docker/pull/532#discussion_r104968111"},"pull_request":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/532"}}},"pull_request":{"url":"https://api.github.com/repos/ceph/ceph-docker/pulls/532","id":109670853,"html_url":"https://github.com/ceph/ceph-docker/pull/532","diff_url":"https://github.com/ceph/ceph-docker/pull/532.diff","patch_url":"https://github.com/ceph/ceph-docker/pull/532.patch","issue_url":"https://api.github.com/repos/ceph/ceph-docker/issues/532","number":532,"state":"open","locked":false,"title":"entrypoint: Enabling bash -x with DEBUG environment variable","user":{"login":"ErwanAliasr1","id":4539421,"avatar_url":"https://avatars0.githubusercontent.com/u/4539421?v=3","gravatar_id":"","url":"https://api.github.com/users/ErwanAliasr1","html_url":"https://github.com/ErwanAliasr1","followers_url":"https://api.github.com/users/ErwanAliasr1/followers","following_url":"https://api.github.com/users/ErwanAliasr1/following{/other_user}","gists_url":"https://api.github.com/users/ErwanAliasr1/gists{/gist_id}","starred_url":"https://api.github.com/users/ErwanAliasr1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ErwanAliasr1/subscriptions","organizations_url":"https://api.github.com/users/ErwanAliasr1/orgs","repos_url":"https://api.github.com/users/ErwanAliasr1/repos","events_url":"https://api.github.com/users/ErwanAliasr1/events{/privacy}","received_events_url":"https://api.github.com/users/ErwanAliasr1/received_events","type":"User","site_admin":false},"body":"If a container fails to start, it's pretty complicated to understand what went wrong and why.\r\nAs per the container thing, it's even more difficult as if a command fails, the container stops making any tracing impossible.\r\nIf you can't modify the container, then it's pretty difficult to analyse the issue.\r\n\r\nThis patch offer to \"control\" the verbosity of bash with a DEBUG environement variable.\r\n\r\nIf you need to trace a particular container, just set DEBUG to any value at run time like :\r\n    sudo docker run -d --name ceph-mon -e DEBUG=1 -e NETWORK_AUTO_DETECT=1 daemon mon\r\n\r\nLater, if we want various behavior, we could read the value of DEBUG and trigger different options.\r\nThis first patch makes things easy by just considering the presence and not the value of DEBUG.","created_at":"2017-03-08T10:46:46Z","updated_at":"2017-03-08T17:07:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"01a50def02d95ab632d5a73344c4320c5f63c7c5","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/ceph/ceph-docker/pulls/532/commits","review_comments_url":"https://api.github.com/repos/ceph/ceph-docker/pulls/532/comments","review_comment_url":"https://api.github.com/repos/ceph/ceph-docker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ceph/ceph-docker/issues/532/comments","statuses_url":"https://api.github.com/repos/ceph/ceph-docker/statuses/c61e9093dabd9f3cbeb9d8a28299b301ff2b09fc","head":{"label":"ceph:evelu-debug","ref":"evelu-debug","sha":"c61e9093dabd9f3cbeb9d8a28299b301ff2b09fc","user":{"login":"ceph","id":1015767,"avatar_url":"https://avatars0.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"repo":{"id":29601598,"name":"ceph-docker","full_name":"ceph/ceph-docker","owner":{"login":"ceph","id":1015767,"avatar_url":"https://avatars0.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ceph/ceph-docker","description":"Docker files and images to run Ceph in containers","fork":false,"url":"https://api.github.com/repos/ceph/ceph-docker","forks_url":"https://api.github.com/repos/ceph/ceph-docker/forks","keys_url":"https://api.github.com/repos/ceph/ceph-docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ceph/ceph-docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ceph/ceph-docker/teams","hooks_url":"https://api.github.com/repos/ceph/ceph-docker/hooks","issue_events_url":"https://api.github.com/repos/ceph/ceph-docker/issues/events{/number}","events_url":"https://api.github.com/repos/ceph/ceph-docker/events","assignees_url":"https://api.github.com/repos/ceph/ceph-docker/assignees{/user}","branches_url":"https://api.github.com/repos/ceph/ceph-docker/branches{/branch}","tags_url":"https://api.github.com/repos/ceph/ceph-docker/tags","blobs_url":"https://api.github.com/repos/ceph/ceph-docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ceph/ceph-docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ceph/ceph-docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/ceph/ceph-docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ceph/ceph-docker/statuses/{sha}","languages_url":"https://api.github.com/repos/ceph/ceph-docker/languages","stargazers_url":"https://api.github.com/repos/ceph/ceph-docker/stargazers","contributors_url":"https://api.github.com/repos/ceph/ceph-docker/contributors","subscribers_url":"https://api.github.com/repos/ceph/ceph-docker/subscribers","subscription_url":"https://api.github.com/repos/ceph/ceph-docker/subscription","commits_url":"https://api.github.com/repos/ceph/ceph-docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/ceph/ceph-docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/ceph/ceph-docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/ceph/ceph-docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/ceph/ceph-docker/contents/{+path}","compare_url":"https://api.github.com/repos/ceph/ceph-docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ceph/ceph-docker/merges","archive_url":"https://api.github.com/repos/ceph/ceph-docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ceph/ceph-docker/downloads","issues_url":"https://api.github.com/repos/ceph/ceph-docker/issues{/number}","pulls_url":"https://api.github.com/repos/ceph/ceph-docker/pulls{/number}","milestones_url":"https://api.github.com/repos/ceph/ceph-docker/milestones{/number}","notifications_url":"https://api.github.com/repos/ceph/ceph-docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ceph/ceph-docker/labels{/name}","releases_url":"https://api.github.com/repos/ceph/ceph-docker/releases{/id}","deployments_url":"https://api.github.com/repos/ceph/ceph-docker/deployments","created_at":"2015-01-21T17:22:51Z","updated_at":"2017-03-08T09:34:08Z","pushed_at":"2017-03-08T17:07:12Z","git_url":"git://github.com/ceph/ceph-docker.git","ssh_url":"git@github.com:ceph/ceph-docker.git","clone_url":"https://github.com/ceph/ceph-docker.git","svn_url":"https://github.com/ceph/ceph-docker","homepage":null,"size":6379,"stargazers_count":434,"watchers_count":434,"language":"Shell","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":213,"mirror_url":null,"open_issues_count":54,"forks":213,"open_issues":54,"watchers":434,"default_branch":"master"}},"base":{"label":"ceph:master","ref":"master","sha":"3b318ef6a912934f49fbc5a084c4a647362ba872","user":{"login":"ceph","id":1015767,"avatar_url":"https://avatars0.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"repo":{"id":29601598,"name":"ceph-docker","full_name":"ceph/ceph-docker","owner":{"login":"ceph","id":1015767,"avatar_url":"https://avatars0.githubusercontent.com/u/1015767?v=3","gravatar_id":"","url":"https://api.github.com/users/ceph","html_url":"https://github.com/ceph","followers_url":"https://api.github.com/users/ceph/followers","following_url":"https://api.github.com/users/ceph/following{/other_user}","gists_url":"https://api.github.com/users/ceph/gists{/gist_id}","starred_url":"https://api.github.com/users/ceph/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ceph/subscriptions","organizations_url":"https://api.github.com/users/ceph/orgs","repos_url":"https://api.github.com/users/ceph/repos","events_url":"https://api.github.com/users/ceph/events{/privacy}","received_events_url":"https://api.github.com/users/ceph/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ceph/ceph-docker","description":"Docker files and images to run Ceph in containers","fork":false,"url":"https://api.github.com/repos/ceph/ceph-docker","forks_url":"https://api.github.com/repos/ceph/ceph-docker/forks","keys_url":"https://api.github.com/repos/ceph/ceph-docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ceph/ceph-docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ceph/ceph-docker/teams","hooks_url":"https://api.github.com/repos/ceph/ceph-docker/hooks","issue_events_url":"https://api.github.com/repos/ceph/ceph-docker/issues/events{/number}","events_url":"https://api.github.com/repos/ceph/ceph-docker/events","assignees_url":"https://api.github.com/repos/ceph/ceph-docker/assignees{/user}","branches_url":"https://api.github.com/repos/ceph/ceph-docker/branches{/branch}","tags_url":"https://api.github.com/repos/ceph/ceph-docker/tags","blobs_url":"https://api.github.com/repos/ceph/ceph-docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ceph/ceph-docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ceph/ceph-docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/ceph/ceph-docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ceph/ceph-docker/statuses/{sha}","languages_url":"https://api.github.com/repos/ceph/ceph-docker/languages","stargazers_url":"https://api.github.com/repos/ceph/ceph-docker/stargazers","contributors_url":"https://api.github.com/repos/ceph/ceph-docker/contributors","subscribers_url":"https://api.github.com/repos/ceph/ceph-docker/subscribers","subscription_url":"https://api.github.com/repos/ceph/ceph-docker/subscription","commits_url":"https://api.github.com/repos/ceph/ceph-docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/ceph/ceph-docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/ceph/ceph-docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/ceph/ceph-docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/ceph/ceph-docker/contents/{+path}","compare_url":"https://api.github.com/repos/ceph/ceph-docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ceph/ceph-docker/merges","archive_url":"https://api.github.com/repos/ceph/ceph-docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ceph/ceph-docker/downloads","issues_url":"https://api.github.com/repos/ceph/ceph-docker/issues{/number}","pulls_url":"https://api.github.com/repos/ceph/ceph-docker/pulls{/number}","milestones_url":"https://api.github.com/repos/ceph/ceph-docker/milestones{/number}","notifications_url":"https://api.github.com/repos/ceph/ceph-docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ceph/ceph-docker/labels{/name}","releases_url":"https://api.github.com/repos/ceph/ceph-docker/releases{/id}","deployments_url":"https://api.github.com/repos/ceph/ceph-docker/deployments","created_at":"2015-01-21T17:22:51Z","updated_at":"2017-03-08T09:34:08Z","pushed_at":"2017-03-08T17:07:12Z","git_url":"git://github.com/ceph/ceph-docker.git","ssh_url":"git@github.com:ceph/ceph-docker.git","clone_url":"https://github.com/ceph/ceph-docker.git","svn_url":"https://github.com/ceph/ceph-docker","homepage":null,"size":6379,"stargazers_count":434,"watchers_count":434,"language":"Shell","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":213,"mirror_url":null,"open_issues_count":54,"forks":213,"open_issues":54,"watchers":434,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/532"},"html":{"href":"https://github.com/ceph/ceph-docker/pull/532"},"issue":{"href":"https://api.github.com/repos/ceph/ceph-docker/issues/532"},"comments":{"href":"https://api.github.com/repos/ceph/ceph-docker/issues/532/comments"},"review_comments":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/532/comments"},"review_comment":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ceph/ceph-docker/pulls/532/commits"},"statuses":{"href":"https://api.github.com/repos/ceph/ceph-docker/statuses/c61e9093dabd9f3cbeb9d8a28299b301ff2b09fc"}}}}
{"actor":{"display_login":"leseb"}}