{"action":"created","issue":{"url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/9","labels_url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/9/comments","events_url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/9/events","html_url":"https://github.com/CenturyLinkLabs/dockerfile-from-image/issues/9","id":108811110,"number":9,"title":"bug about the USER directive","user":{"login":"k3ck3c","id":3126227,"avatar_url":"https://avatars.githubusercontent.com/u/3126227?v=3","gravatar_id":"","url":"https://api.github.com/users/k3ck3c","html_url":"https://github.com/k3ck3c","followers_url":"https://api.github.com/users/k3ck3c/followers","following_url":"https://api.github.com/users/k3ck3c/following{/other_user}","gists_url":"https://api.github.com/users/k3ck3c/gists{/gist_id}","starred_url":"https://api.github.com/users/k3ck3c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k3ck3c/subscriptions","organizations_url":"https://api.github.com/users/k3ck3c/orgs","repos_url":"https://api.github.com/users/k3ck3c/repos","events_url":"https://api.github.com/users/k3ck3c/events{/privacy}","received_events_url":"https://api.github.com/users/k3ck3c/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-09-29T07:34:57Z","updated_at":"2015-11-25T06:54:32Z","closed_at":null,"body":"a buglet\r\n\r\nWhen launching \r\n\r\ndocker run -v /var/run/docker.sock:/var/run/docker.sock   centurylink/dockerfile-from-image k3ck3c/captvty\r\n\r\nI get, among other things\r\n\r\nUSER [gg]\r\n\r\nwhen it should be \r\n\r\nUSER gg\r\n\r\nof course the created Dockerfile does not work, as this is not a \"legal\" user.\r\n\r\nThanks for this great tool.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/comments/159516072","html_url":"https://github.com/CenturyLinkLabs/dockerfile-from-image/issues/9#issuecomment-159516072","issue_url":"https://api.github.com/repos/CenturyLinkLabs/dockerfile-from-image/issues/9","id":159516072,"user":{"login":"SydOps","id":8954908,"avatar_url":"https://avatars.githubusercontent.com/u/8954908?v=3","gravatar_id":"","url":"https://api.github.com/users/SydOps","html_url":"https://github.com/SydOps","followers_url":"https://api.github.com/users/SydOps/followers","following_url":"https://api.github.com/users/SydOps/following{/other_user}","gists_url":"https://api.github.com/users/SydOps/gists{/gist_id}","starred_url":"https://api.github.com/users/SydOps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SydOps/subscriptions","organizations_url":"https://api.github.com/users/SydOps/orgs","repos_url":"https://api.github.com/users/SydOps/repos","events_url":"https://api.github.com/users/SydOps/events{/privacy}","received_events_url":"https://api.github.com/users/SydOps/received_events","type":"User","site_admin":false},"created_at":"2015-11-25T06:54:32Z","updated_at":"2015-11-25T06:54:32Z","body":"I have duplicated the issue\r\n```\r\n$ cat Dockerfile\r\nFROM ruby\r\nUSER gg\r\n\r\n$ docker build -t test .\r\nSending build context to Docker daemon 2.048 kB\r\nStep 1 : FROM ruby\r\n ---> a930a50e60f8\r\nStep 2 : USER gg\r\n ---> Using cache\r\n ---> db680ba9a608\r\nSuccessfully built db680ba9a608\r\n\r\n$ dfimage test\r\nFROM ruby:latest\r\nUSER [gg]\r\n```\r\nSo we need add one `if-else` statement as https://github.com/CenturyLinkLabs/dockerfile-from-image/blob/master/dockerfile-from-image.rb#L56 to remove `[]` from USER command."}}