{"action":"created","issue":{"url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/249","repository_url":"https://api.github.com/repos/SeleniumHQ/docker-selenium","labels_url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/249/labels{/name}","comments_url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/249/comments","events_url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/249/events","html_url":"https://github.com/SeleniumHQ/docker-selenium/pull/249","id":166693463,"number":249,"title":"Fix xvfb-run failure when environment variables with spaces exist","user":{"login":"chuckg","id":65832,"avatar_url":"https://avatars2.githubusercontent.com/u/65832?v=3","gravatar_id":"","url":"https://api.github.com/users/chuckg","html_url":"https://github.com/chuckg","followers_url":"https://api.github.com/users/chuckg/followers","following_url":"https://api.github.com/users/chuckg/following{/other_user}","gists_url":"https://api.github.com/users/chuckg/gists{/gist_id}","starred_url":"https://api.github.com/users/chuckg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chuckg/subscriptions","organizations_url":"https://api.github.com/users/chuckg/orgs","repos_url":"https://api.github.com/users/chuckg/repos","events_url":"https://api.github.com/users/chuckg/events{/privacy}","received_events_url":"https://api.github.com/users/chuckg/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":13,"created_at":"2016-07-20T22:05:45Z","updated_at":"2017-03-23T17:55:07Z","closed_at":"2017-03-23T17:52:42Z","pull_request":{"url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/pulls/249","html_url":"https://github.com/SeleniumHQ/docker-selenium/pull/249","diff_url":"https://github.com/SeleniumHQ/docker-selenium/pull/249.diff","patch_url":"https://github.com/SeleniumHQ/docker-selenium/pull/249.patch"},"body":"## Description\n\nThere is a bug in the StandaloneDebug `entry_point.sh` that, when encountering an environment variable with a space in it's value, causes the `xvfb-run ...` step to fail. This is due to how the command inlines environment variables found in the root user's environment that  are not present in the seluser's environment into the `xvfb-run ...` step. \n## Notes\n- Initially tried fixing the inline, but couldn't get the return codes to work with all the subshell slinging, so I opted for an environment file and simply sourcing it inline with the `xvfb-run ...`\n- Thought using envdir instead instead, but opted for not adding packages and going at it in a more traditional way.\n- Resolves #227\n- The issue was originally introduced in https://github.com/SeleniumHQ/docker-selenium/pull/131\n## How to reproduce\n\nAfter adding an environment variable with a space, ie: `NO_PROXY=\"*.local, 10.254/16\"` to my `docker run`, the error is immediately reproducible:\n\n```\n$ make standalone_chrome_debug\n...\nSuccessfully built 6a0b1ab25668\n\n$ docker run -e NO_PROXY=\"*.local, 10.254/16\" --rm selenium/standalone-chrome-debug:2.53.0 env\nPATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\nHOSTNAME=6a00c5bf0dd2\nNO_PROXY=*.local, 10.254/16\nDEBIAN_FRONTEND=noninteractive\nDEBCONF_NONINTERACTIVE_SEEN=true\nTZ=US/Pacific\nSCREEN_WIDTH=1360\nSCREEN_HEIGHT=1020\nSCREEN_DEPTH=24\nDISPLAY=:99.0\nCHROME_DRIVER_VERSION=2.21\nDBUS_SESSION_BUS_ADDRESS=/dev/null\nLANGUAGE=en_US.UTF-8\nLANG=en_US.UTF-8\nHOME=/root\n\n$ docker run -e NO_PROXY=\"*.local, 10.254/16\" --rm selenium/standalone-chrome-debug:2.53.0\nWaiting xvfb...\n-bash: 10.254/16: No such file or directory\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\nWaiting xvfb...\n```\n## Testing\n\n```\n$ git checkout fix/xvfb-run_env_constructor\n$ make standalone_chrome_debug\n$ docker run -e NO_PROXY=\"*.local, 10.254/16\" --rm selenium/standalone-chrome-debug:2.53.0\nWaiting xvfb...\nFailed to read: session.ignoreBorder\nSetting default value\n...\n20/07/2016 15:03:47 screen setup finished.\n20/07/2016 15:03:47\n\nThe VNC desktop is:      c5399f058668:0\n...\n<etc>\n```\n"},"comment":{"url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/comments/288806959","html_url":"https://github.com/SeleniumHQ/docker-selenium/pull/249#issuecomment-288806959","issue_url":"https://api.github.com/repos/SeleniumHQ/docker-selenium/issues/249","id":288806959,"user":{"login":"ddavison","id":2972876,"avatar_url":"https://avatars0.githubusercontent.com/u/2972876?v=3","gravatar_id":"","url":"https://api.github.com/users/ddavison","html_url":"https://github.com/ddavison","followers_url":"https://api.github.com/users/ddavison/followers","following_url":"https://api.github.com/users/ddavison/following{/other_user}","gists_url":"https://api.github.com/users/ddavison/gists{/gist_id}","starred_url":"https://api.github.com/users/ddavison/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ddavison/subscriptions","organizations_url":"https://api.github.com/users/ddavison/orgs","repos_url":"https://api.github.com/users/ddavison/repos","events_url":"https://api.github.com/users/ddavison/events{/privacy}","received_events_url":"https://api.github.com/users/ddavison/received_events","type":"User","site_admin":false},"created_at":"2017-03-23T17:55:07Z","updated_at":"2017-03-23T17:55:07Z","body":"merged in! working on releasing 3.2.0-actinium as we speak"}}
{"actor":{"display_login":"ddavison"}}