{"action":"created","comment":{"url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/comments/42199225","id":42199225,"diff_hunk":"@@ -35,18 +36,10 @@ def daemonize(func=None):\n     if procid == -1:\n         sys.exit(1)\n \n-    # Close open file descriptors\n-    for fd in (0, 1, 2):\n-        try:\n-            os.close(fd)\n-        except OSError:\n-            pass\n-\n-    print(\"about to point fds to null\")\n-    # Point descriptors to /dev/null\n-    os.open(\"/dev/null\", os.O_RDWR)\n-    os.dup(0)\n-    os.dup(0)\n+    # output descriptors point to log file\n+    f = os.open(log_file, os.O_WRONLY|os.O_APPEND)\n+    os.dup2(f, 1)\n+    os.dup2(f, 2)","path":"eucaconsole","position":27,"original_position":27,"commit_id":"04cca474ff190a08e0ddc449183d14ec294e4011","original_commit_id":"04cca474ff190a08e0ddc449183d14ec294e4011","user":{"login":"gholms","id":92943,"avatar_url":"https://avatars.githubusercontent.com/u/92943?v=3","gravatar_id":"","url":"https://api.github.com/users/gholms","html_url":"https://github.com/gholms","followers_url":"https://api.github.com/users/gholms/followers","following_url":"https://api.github.com/users/gholms/following{/other_user}","gists_url":"https://api.github.com/users/gholms/gists{/gist_id}","starred_url":"https://api.github.com/users/gholms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gholms/subscriptions","organizations_url":"https://api.github.com/users/gholms/orgs","repos_url":"https://api.github.com/users/gholms/repos","events_url":"https://api.github.com/users/gholms/events{/privacy}","received_events_url":"https://api.github.com/users/gholms/received_events","type":"User","site_admin":false},"body":"Shouldn't this still be closing stdin?  (I'd assume the high-level functions are fine for that.)","created_at":"2015-10-16T00:47:03Z","updated_at":"2015-10-16T00:47:03Z","html_url":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5#discussion_r42199225","pull_request_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/comments/42199225"},"html":{"href":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5#discussion_r42199225"},"pull_request":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5","id":44210878,"html_url":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5","diff_url":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5.diff","patch_url":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5.patch","issue_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/5","number":5,"state":"open","locked":false,"title":"GUI-1749 direct all output from service to std logfile","user":{"login":"dkavanagh","id":367566,"avatar_url":"https://avatars.githubusercontent.com/u/367566?v=3","gravatar_id":"","url":"https://api.github.com/users/dkavanagh","html_url":"https://github.com/dkavanagh","followers_url":"https://api.github.com/users/dkavanagh/followers","following_url":"https://api.github.com/users/dkavanagh/following{/other_user}","gists_url":"https://api.github.com/users/dkavanagh/gists{/gist_id}","starred_url":"https://api.github.com/users/dkavanagh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dkavanagh/subscriptions","organizations_url":"https://api.github.com/users/dkavanagh/orgs","repos_url":"https://api.github.com/users/dkavanagh/repos","events_url":"https://api.github.com/users/dkavanagh/events{/privacy}","received_events_url":"https://api.github.com/users/dkavanagh/received_events","type":"User","site_admin":false},"body":"direct all output from service to std logfile","created_at":"2015-09-04T12:09:46Z","updated_at":"2015-10-16T00:47:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3242595e8d35fb25f7b48d3783d3989530b06312","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5/commits","review_comments_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5/comments","review_comment_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/comments{/number}","comments_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/5/comments","statuses_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/statuses/04cca474ff190a08e0ddc449183d14ec294e4011","head":{"label":"eucalyptus:GUI-1749","ref":"GUI-1749","sha":"04cca474ff190a08e0ddc449183d14ec294e4011","user":{"login":"eucalyptus","id":808244,"avatar_url":"https://avatars.githubusercontent.com/u/808244?v=3","gravatar_id":"","url":"https://api.github.com/users/eucalyptus","html_url":"https://github.com/eucalyptus","followers_url":"https://api.github.com/users/eucalyptus/followers","following_url":"https://api.github.com/users/eucalyptus/following{/other_user}","gists_url":"https://api.github.com/users/eucalyptus/gists{/gist_id}","starred_url":"https://api.github.com/users/eucalyptus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eucalyptus/subscriptions","organizations_url":"https://api.github.com/users/eucalyptus/orgs","repos_url":"https://api.github.com/users/eucalyptus/repos","events_url":"https://api.github.com/users/eucalyptus/events{/privacy}","received_events_url":"https://api.github.com/users/eucalyptus/received_events","type":"Organization","site_admin":false},"repo":{"id":17547802,"name":"eucaconsole-rpmspec","full_name":"eucalyptus/eucaconsole-rpmspec","owner":{"login":"eucalyptus","id":808244,"avatar_url":"https://avatars.githubusercontent.com/u/808244?v=3","gravatar_id":"","url":"https://api.github.com/users/eucalyptus","html_url":"https://github.com/eucalyptus","followers_url":"https://api.github.com/users/eucalyptus/followers","following_url":"https://api.github.com/users/eucalyptus/following{/other_user}","gists_url":"https://api.github.com/users/eucalyptus/gists{/gist_id}","starred_url":"https://api.github.com/users/eucalyptus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eucalyptus/subscriptions","organizations_url":"https://api.github.com/users/eucalyptus/orgs","repos_url":"https://api.github.com/users/eucalyptus/repos","events_url":"https://api.github.com/users/eucalyptus/events{/privacy}","received_events_url":"https://api.github.com/users/eucalyptus/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/eucalyptus/eucaconsole-rpmspec","description":"RPM packaging bits for eucaconsole","fork":false,"url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec","forks_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/forks","keys_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/teams","hooks_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/hooks","issue_events_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/events{/number}","events_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/events","assignees_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/assignees{/user}","branches_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/branches{/branch}","tags_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/tags","blobs_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/refs{/sha}","trees_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/statuses/{sha}","languages_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/languages","stargazers_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/stargazers","contributors_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/contributors","subscribers_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/subscribers","subscription_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/subscription","commits_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/commits{/sha}","git_commits_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/commits{/sha}","comments_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/comments{/number}","issue_comment_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/comments{/number}","contents_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/contents/{+path}","compare_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/merges","archive_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/downloads","issues_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues{/number}","pulls_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls{/number}","milestones_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/milestones{/number}","notifications_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/labels{/name}","releases_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/releases{/id}","created_at":"2014-03-08T18:13:25Z","updated_at":"2015-04-17T19:56:00Z","pushed_at":"2015-10-12T14:30:07Z","git_url":"git://github.com/eucalyptus/eucaconsole-rpmspec.git","ssh_url":"git@github.com:eucalyptus/eucaconsole-rpmspec.git","clone_url":"https://github.com/eucalyptus/eucaconsole-rpmspec.git","svn_url":"https://github.com/eucalyptus/eucaconsole-rpmspec","homepage":"","size":462,"stargazers_count":0,"watchers_count":0,"language":"Shell","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":1,"forks":3,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"eucalyptus:master","ref":"master","sha":"864a691f895ea22040418d57a5aa0ab8ed992d90","user":{"login":"eucalyptus","id":808244,"avatar_url":"https://avatars.githubusercontent.com/u/808244?v=3","gravatar_id":"","url":"https://api.github.com/users/eucalyptus","html_url":"https://github.com/eucalyptus","followers_url":"https://api.github.com/users/eucalyptus/followers","following_url":"https://api.github.com/users/eucalyptus/following{/other_user}","gists_url":"https://api.github.com/users/eucalyptus/gists{/gist_id}","starred_url":"https://api.github.com/users/eucalyptus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eucalyptus/subscriptions","organizations_url":"https://api.github.com/users/eucalyptus/orgs","repos_url":"https://api.github.com/users/eucalyptus/repos","events_url":"https://api.github.com/users/eucalyptus/events{/privacy}","received_events_url":"https://api.github.com/users/eucalyptus/received_events","type":"Organization","site_admin":false},"repo":{"id":17547802,"name":"eucaconsole-rpmspec","full_name":"eucalyptus/eucaconsole-rpmspec","owner":{"login":"eucalyptus","id":808244,"avatar_url":"https://avatars.githubusercontent.com/u/808244?v=3","gravatar_id":"","url":"https://api.github.com/users/eucalyptus","html_url":"https://github.com/eucalyptus","followers_url":"https://api.github.com/users/eucalyptus/followers","following_url":"https://api.github.com/users/eucalyptus/following{/other_user}","gists_url":"https://api.github.com/users/eucalyptus/gists{/gist_id}","starred_url":"https://api.github.com/users/eucalyptus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eucalyptus/subscriptions","organizations_url":"https://api.github.com/users/eucalyptus/orgs","repos_url":"https://api.github.com/users/eucalyptus/repos","events_url":"https://api.github.com/users/eucalyptus/events{/privacy}","received_events_url":"https://api.github.com/users/eucalyptus/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/eucalyptus/eucaconsole-rpmspec","description":"RPM packaging bits for eucaconsole","fork":false,"url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec","forks_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/forks","keys_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/teams","hooks_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/hooks","issue_events_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/events{/number}","events_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/events","assignees_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/assignees{/user}","branches_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/branches{/branch}","tags_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/tags","blobs_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/refs{/sha}","trees_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/statuses/{sha}","languages_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/languages","stargazers_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/stargazers","contributors_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/contributors","subscribers_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/subscribers","subscription_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/subscription","commits_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/commits{/sha}","git_commits_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/git/commits{/sha}","comments_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/comments{/number}","issue_comment_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/comments{/number}","contents_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/contents/{+path}","compare_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/merges","archive_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/downloads","issues_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues{/number}","pulls_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls{/number}","milestones_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/milestones{/number}","notifications_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/labels{/name}","releases_url":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/releases{/id}","created_at":"2014-03-08T18:13:25Z","updated_at":"2015-04-17T19:56:00Z","pushed_at":"2015-10-12T14:30:07Z","git_url":"git://github.com/eucalyptus/eucaconsole-rpmspec.git","ssh_url":"git@github.com:eucalyptus/eucaconsole-rpmspec.git","clone_url":"https://github.com/eucalyptus/eucaconsole-rpmspec.git","svn_url":"https://github.com/eucalyptus/eucaconsole-rpmspec","homepage":"","size":462,"stargazers_count":0,"watchers_count":0,"language":"Shell","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":1,"forks":3,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5"},"html":{"href":"https://github.com/eucalyptus/eucaconsole-rpmspec/pull/5"},"issue":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/5"},"comments":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/eucalyptus/eucaconsole-rpmspec/statuses/04cca474ff190a08e0ddc449183d14ec294e4011"}}}}