{"action":"opened","issue":{"url":"https://api.github.com/repos/amir20/phantomjs-node/issues/353","repository_url":"https://api.github.com/repos/amir20/phantomjs-node","labels_url":"https://api.github.com/repos/amir20/phantomjs-node/issues/353/labels{/name}","comments_url":"https://api.github.com/repos/amir20/phantomjs-node/issues/353/comments","events_url":"https://api.github.com/repos/amir20/phantomjs-node/issues/353/events","html_url":"https://github.com/amir20/phantomjs-node/issues/353","id":131435460,"number":353,"title":"Running within a Docker container","user":{"login":"PaulTondeur","id":141029,"avatar_url":"https://avatars.githubusercontent.com/u/141029?v=3","gravatar_id":"","url":"https://api.github.com/users/PaulTondeur","html_url":"https://github.com/PaulTondeur","followers_url":"https://api.github.com/users/PaulTondeur/followers","following_url":"https://api.github.com/users/PaulTondeur/following{/other_user}","gists_url":"https://api.github.com/users/PaulTondeur/gists{/gist_id}","starred_url":"https://api.github.com/users/PaulTondeur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PaulTondeur/subscriptions","organizations_url":"https://api.github.com/users/PaulTondeur/orgs","repos_url":"https://api.github.com/users/PaulTondeur/repos","events_url":"https://api.github.com/users/PaulTondeur/events{/privacy}","received_events_url":"https://api.github.com/users/PaulTondeur/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-02-04T18:32:06Z","updated_at":"2016-02-04T18:32:06Z","closed_at":null,"body":"When running phantom within a docker container I get the following error:\r\n\r\n```\r\nNETWORK_ERR: XMLHttpRequest Exception 101: A network error occurred in synchronous requests\r\n```\r\n\r\nWhen running this directly on my machine or when running phantomjs directly (within a Docker container) I won't get this error. It turns out that I have to create a phantomjs instance with disabled web security:\r\n\r\n```\r\nphantom.create(callback,{parameters:{'web-security':'no'}})\r\n```\r\n\r\nI don't know why I have to configure phantom this way while in a Docker container, but it took me quite some hours to figure out. \r\n\r\nI'm reporting here in the hope this will save others time in the future and maybe to get a reply by someone who knows why this happens as I don't think it is a bug with this project."}}