{"action":"created","comment":{"url":"https://api.github.com/repos/docker/docker/pulls/comments/35465841","id":35465841,"diff_hunk":"@@ -37,11 +37,13 @@ type (\n \t\tCompression      Compression\n \t\tNoLchown         bool\n \t\tChownOpts        *TarChownOptions\n-\t\tName             string","path":"pkg/archive/archive.go","position":4,"original_position":4,"commit_id":"472d5de67d0435e45e6e8f70921d957dbaa07c9a","original_commit_id":"472d5de67d0435e45e6e8f70921d957dbaa07c9a","user":{"login":"jlhawn","id":1441929,"avatar_url":"https://avatars.githubusercontent.com/u/1441929?v=3","gravatar_id":"","url":"https://api.github.com/users/jlhawn","html_url":"https://github.com/jlhawn","followers_url":"https://api.github.com/users/jlhawn/followers","following_url":"https://api.github.com/users/jlhawn/following{/other_user}","gists_url":"https://api.github.com/users/jlhawn/gists{/gist_id}","starred_url":"https://api.github.com/users/jlhawn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlhawn/subscriptions","organizations_url":"https://api.github.com/users/jlhawn/orgs","repos_url":"https://api.github.com/users/jlhawn/repos","events_url":"https://api.github.com/users/jlhawn/events{/privacy}","received_events_url":"https://api.github.com/users/jlhawn/received_events","type":"User","site_admin":false},"body":"Rationale for removing this: It is never used, we have logic that uses it below, but I replaced it with the `rebaseNames` map.","created_at":"2015-07-24T21:06:28Z","updated_at":"2015-07-24T21:06:28Z","html_url":"https://github.com/docker/docker/pull/14885#discussion_r35465841","pull_request_url":"https://api.github.com/repos/docker/docker/pulls/14885","_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/comments/35465841"},"html":{"href":"https://github.com/docker/docker/pull/14885#discussion_r35465841"},"pull_request":{"href":"https://api.github.com/repos/docker/docker/pulls/14885"}}},"pull_request":{"url":"https://api.github.com/repos/docker/docker/pulls/14885","id":40627743,"html_url":"https://github.com/docker/docker/pull/14885","diff_url":"https://github.com/docker/docker/pull/14885.diff","patch_url":"https://github.com/docker/docker/pull/14885.patch","issue_url":"https://api.github.com/repos/docker/docker/issues/14885","number":14885,"state":"open","locked":false,"title":"Fix copying of symlinks in containers","user":{"login":"jlhawn","id":1441929,"avatar_url":"https://avatars.githubusercontent.com/u/1441929?v=3","gravatar_id":"","url":"https://api.github.com/users/jlhawn","html_url":"https://github.com/jlhawn","followers_url":"https://api.github.com/users/jlhawn/followers","following_url":"https://api.github.com/users/jlhawn/following{/other_user}","gists_url":"https://api.github.com/users/jlhawn/gists{/gist_id}","starred_url":"https://api.github.com/users/jlhawn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlhawn/subscriptions","organizations_url":"https://api.github.com/users/jlhawn/orgs","repos_url":"https://api.github.com/users/jlhawn/repos","events_url":"https://api.github.com/users/jlhawn/events{/privacy}","received_events_url":"https://api.github.com/users/jlhawn/received_events","type":"User","site_admin":false},"body":"Copying a symlink should do just that: copy the symlink NOT copy the target of the symlink. Also, the resulting file from the copy should have the name of the symlink NOT the name of the target file.\r\n\r\nThis patch includes a fix to *StatPath*, *ArchivePath*, and *ExtractToDir* methods on containers. These operations *should* resolve symlinks that are in the path but if the resource itself is a symlink then it *should not* be resolved. This patch puts this logic into a common function `resolvePath` which resolves symlinks of the path's dir in scope of the container rootfs but does not resolve the final element of the path. Now archive, extract, and stat operations will return symlinks if the path is indeed a symlink.","created_at":"2015-07-23T00:54:38Z","updated_at":"2015-07-24T21:06:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"47e6c57a15d639806a242f8bf0dfc8e9443f0f6e","assignee":null,"milestone":{"url":"https://api.github.com/repos/docker/docker/milestones/39","html_url":"https://github.com/docker/docker/milestones/1.8.0","labels_url":"https://api.github.com/repos/docker/docker/milestones/39/labels","id":1151952,"number":39,"title":"1.8.0","description":"","creator":{"login":"thaJeztah","id":1804568,"avatar_url":"https://avatars.githubusercontent.com/u/1804568?v=3","gravatar_id":"","url":"https://api.github.com/users/thaJeztah","html_url":"https://github.com/thaJeztah","followers_url":"https://api.github.com/users/thaJeztah/followers","following_url":"https://api.github.com/users/thaJeztah/following{/other_user}","gists_url":"https://api.github.com/users/thaJeztah/gists{/gist_id}","starred_url":"https://api.github.com/users/thaJeztah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thaJeztah/subscriptions","organizations_url":"https://api.github.com/users/thaJeztah/orgs","repos_url":"https://api.github.com/users/thaJeztah/repos","events_url":"https://api.github.com/users/thaJeztah/events{/privacy}","received_events_url":"https://api.github.com/users/thaJeztah/received_events","type":"User","site_admin":false},"open_issues":6,"closed_issues":46,"state":"open","created_at":"2015-06-05T19:27:06Z","updated_at":"2015-07-24T20:27:09Z","due_on":"2015-08-09T22:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/docker/docker/pulls/14885/commits","review_comments_url":"https://api.github.com/repos/docker/docker/pulls/14885/comments","review_comment_url":"https://api.github.com/repos/docker/docker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/docker/docker/issues/14885/comments","statuses_url":"https://api.github.com/repos/docker/docker/statuses/472d5de67d0435e45e6e8f70921d957dbaa07c9a","head":{"label":"jlhawn:fix_cp_symlink","ref":"fix_cp_symlink","sha":"472d5de67d0435e45e6e8f70921d957dbaa07c9a","user":{"login":"jlhawn","id":1441929,"avatar_url":"https://avatars.githubusercontent.com/u/1441929?v=3","gravatar_id":"","url":"https://api.github.com/users/jlhawn","html_url":"https://github.com/jlhawn","followers_url":"https://api.github.com/users/jlhawn/followers","following_url":"https://api.github.com/users/jlhawn/following{/other_user}","gists_url":"https://api.github.com/users/jlhawn/gists{/gist_id}","starred_url":"https://api.github.com/users/jlhawn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlhawn/subscriptions","organizations_url":"https://api.github.com/users/jlhawn/orgs","repos_url":"https://api.github.com/users/jlhawn/repos","events_url":"https://api.github.com/users/jlhawn/events{/privacy}","received_events_url":"https://api.github.com/users/jlhawn/received_events","type":"User","site_admin":false},"repo":{"id":14341765,"name":"docker","full_name":"jlhawn/docker","owner":{"login":"jlhawn","id":1441929,"avatar_url":"https://avatars.githubusercontent.com/u/1441929?v=3","gravatar_id":"","url":"https://api.github.com/users/jlhawn","html_url":"https://github.com/jlhawn","followers_url":"https://api.github.com/users/jlhawn/followers","following_url":"https://api.github.com/users/jlhawn/following{/other_user}","gists_url":"https://api.github.com/users/jlhawn/gists{/gist_id}","starred_url":"https://api.github.com/users/jlhawn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jlhawn/subscriptions","organizations_url":"https://api.github.com/users/jlhawn/orgs","repos_url":"https://api.github.com/users/jlhawn/repos","events_url":"https://api.github.com/users/jlhawn/events{/privacy}","received_events_url":"https://api.github.com/users/jlhawn/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jlhawn/docker","description":"Docker - the open-source application container engine","fork":true,"url":"https://api.github.com/repos/jlhawn/docker","forks_url":"https://api.github.com/repos/jlhawn/docker/forks","keys_url":"https://api.github.com/repos/jlhawn/docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jlhawn/docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jlhawn/docker/teams","hooks_url":"https://api.github.com/repos/jlhawn/docker/hooks","issue_events_url":"https://api.github.com/repos/jlhawn/docker/issues/events{/number}","events_url":"https://api.github.com/repos/jlhawn/docker/events","assignees_url":"https://api.github.com/repos/jlhawn/docker/assignees{/user}","branches_url":"https://api.github.com/repos/jlhawn/docker/branches{/branch}","tags_url":"https://api.github.com/repos/jlhawn/docker/tags","blobs_url":"https://api.github.com/repos/jlhawn/docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jlhawn/docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jlhawn/docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/jlhawn/docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jlhawn/docker/statuses/{sha}","languages_url":"https://api.github.com/repos/jlhawn/docker/languages","stargazers_url":"https://api.github.com/repos/jlhawn/docker/stargazers","contributors_url":"https://api.github.com/repos/jlhawn/docker/contributors","subscribers_url":"https://api.github.com/repos/jlhawn/docker/subscribers","subscription_url":"https://api.github.com/repos/jlhawn/docker/subscription","commits_url":"https://api.github.com/repos/jlhawn/docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/jlhawn/docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/jlhawn/docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/jlhawn/docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/jlhawn/docker/contents/{+path}","compare_url":"https://api.github.com/repos/jlhawn/docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jlhawn/docker/merges","archive_url":"https://api.github.com/repos/jlhawn/docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jlhawn/docker/downloads","issues_url":"https://api.github.com/repos/jlhawn/docker/issues{/number}","pulls_url":"https://api.github.com/repos/jlhawn/docker/pulls{/number}","milestones_url":"https://api.github.com/repos/jlhawn/docker/milestones{/number}","notifications_url":"https://api.github.com/repos/jlhawn/docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jlhawn/docker/labels{/name}","releases_url":"https://api.github.com/repos/jlhawn/docker/releases{/id}","created_at":"2013-11-12T18:50:12Z","updated_at":"2015-05-06T21:32:40Z","pushed_at":"2015-07-24T21:02:02Z","git_url":"git://github.com/jlhawn/docker.git","ssh_url":"git@github.com:jlhawn/docker.git","clone_url":"https://github.com/jlhawn/docker.git","svn_url":"https://github.com/jlhawn/docker","homepage":"http://www.docker.io","size":63710,"stargazers_count":5,"watchers_count":5,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":5,"default_branch":"master"}},"base":{"label":"docker:master","ref":"master","sha":"2084eee02c49fba22b2396abc626c1e6c7fc8ec2","user":{"login":"docker","id":5429470,"avatar_url":"https://avatars.githubusercontent.com/u/5429470?v=3","gravatar_id":"","url":"https://api.github.com/users/docker","html_url":"https://github.com/docker","followers_url":"https://api.github.com/users/docker/followers","following_url":"https://api.github.com/users/docker/following{/other_user}","gists_url":"https://api.github.com/users/docker/gists{/gist_id}","starred_url":"https://api.github.com/users/docker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker/subscriptions","organizations_url":"https://api.github.com/users/docker/orgs","repos_url":"https://api.github.com/users/docker/repos","events_url":"https://api.github.com/users/docker/events{/privacy}","received_events_url":"https://api.github.com/users/docker/received_events","type":"Organization","site_admin":false},"repo":{"id":7691631,"name":"docker","full_name":"docker/docker","owner":{"login":"docker","id":5429470,"avatar_url":"https://avatars.githubusercontent.com/u/5429470?v=3","gravatar_id":"","url":"https://api.github.com/users/docker","html_url":"https://github.com/docker","followers_url":"https://api.github.com/users/docker/followers","following_url":"https://api.github.com/users/docker/following{/other_user}","gists_url":"https://api.github.com/users/docker/gists{/gist_id}","starred_url":"https://api.github.com/users/docker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker/subscriptions","organizations_url":"https://api.github.com/users/docker/orgs","repos_url":"https://api.github.com/users/docker/repos","events_url":"https://api.github.com/users/docker/events{/privacy}","received_events_url":"https://api.github.com/users/docker/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/docker/docker","description":"Docker - the open-source application container engine","fork":false,"url":"https://api.github.com/repos/docker/docker","forks_url":"https://api.github.com/repos/docker/docker/forks","keys_url":"https://api.github.com/repos/docker/docker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/docker/docker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/docker/docker/teams","hooks_url":"https://api.github.com/repos/docker/docker/hooks","issue_events_url":"https://api.github.com/repos/docker/docker/issues/events{/number}","events_url":"https://api.github.com/repos/docker/docker/events","assignees_url":"https://api.github.com/repos/docker/docker/assignees{/user}","branches_url":"https://api.github.com/repos/docker/docker/branches{/branch}","tags_url":"https://api.github.com/repos/docker/docker/tags","blobs_url":"https://api.github.com/repos/docker/docker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/docker/docker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/docker/docker/git/refs{/sha}","trees_url":"https://api.github.com/repos/docker/docker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/docker/docker/statuses/{sha}","languages_url":"https://api.github.com/repos/docker/docker/languages","stargazers_url":"https://api.github.com/repos/docker/docker/stargazers","contributors_url":"https://api.github.com/repos/docker/docker/contributors","subscribers_url":"https://api.github.com/repos/docker/docker/subscribers","subscription_url":"https://api.github.com/repos/docker/docker/subscription","commits_url":"https://api.github.com/repos/docker/docker/commits{/sha}","git_commits_url":"https://api.github.com/repos/docker/docker/git/commits{/sha}","comments_url":"https://api.github.com/repos/docker/docker/comments{/number}","issue_comment_url":"https://api.github.com/repos/docker/docker/issues/comments{/number}","contents_url":"https://api.github.com/repos/docker/docker/contents/{+path}","compare_url":"https://api.github.com/repos/docker/docker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/docker/docker/merges","archive_url":"https://api.github.com/repos/docker/docker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/docker/docker/downloads","issues_url":"https://api.github.com/repos/docker/docker/issues{/number}","pulls_url":"https://api.github.com/repos/docker/docker/pulls{/number}","milestones_url":"https://api.github.com/repos/docker/docker/milestones{/number}","notifications_url":"https://api.github.com/repos/docker/docker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/docker/docker/labels{/name}","releases_url":"https://api.github.com/repos/docker/docker/releases{/id}","created_at":"2013-01-18T18:10:57Z","updated_at":"2015-07-24T20:16:15Z","pushed_at":"2015-07-24T21:05:12Z","git_url":"git://github.com/docker/docker.git","ssh_url":"git@github.com:docker/docker.git","clone_url":"https://github.com/docker/docker.git","svn_url":"https://github.com/docker/docker","homepage":"http://www.docker.com","size":230723,"stargazers_count":23510,"watchers_count":23510,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5884,"mirror_url":null,"open_issues_count":1056,"forks":5884,"open_issues":1056,"watchers":23510,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/docker/docker/pulls/14885"},"html":{"href":"https://github.com/docker/docker/pull/14885"},"issue":{"href":"https://api.github.com/repos/docker/docker/issues/14885"},"comments":{"href":"https://api.github.com/repos/docker/docker/issues/14885/comments"},"review_comments":{"href":"https://api.github.com/repos/docker/docker/pulls/14885/comments"},"review_comment":{"href":"https://api.github.com/repos/docker/docker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/docker/docker/pulls/14885/commits"},"statuses":{"href":"https://api.github.com/repos/docker/docker/statuses/472d5de67d0435e45e6e8f70921d957dbaa07c9a"}}}}