{"action":"created","issue":{"url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/226","labels_url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/226/labels{/name}","comments_url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/226/comments","events_url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/226/events","html_url":"https://github.com/cloudfoundry-incubator/lattice-release/issues/226","id":113485712,"number":226,"title":"Lattice 0.6.0 Vagrantfile doesn't seem to work over proxies any more","user":{"login":"mbechauf","id":10136148,"avatar_url":"https://avatars.githubusercontent.com/u/10136148?v=3","gravatar_id":"","url":"https://api.github.com/users/mbechauf","html_url":"https://github.com/mbechauf","followers_url":"https://api.github.com/users/mbechauf/followers","following_url":"https://api.github.com/users/mbechauf/following{/other_user}","gists_url":"https://api.github.com/users/mbechauf/gists{/gist_id}","starred_url":"https://api.github.com/users/mbechauf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbechauf/subscriptions","organizations_url":"https://api.github.com/users/mbechauf/orgs","repos_url":"https://api.github.com/users/mbechauf/repos","events_url":"https://api.github.com/users/mbechauf/events{/privacy}","received_events_url":"https://api.github.com/users/mbechauf/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-27T01:28:26Z","updated_at":"2015-10-27T02:17:29Z","closed_at":null,"body":"Used to work without a problem with 0.5.0 and lower. \r\n\r\nVagrant version 1.7.2 on Windows \r\n\r\nIt appears that the change from curl to Net::HTTP is the culprit. The only way I get it to work is to pass the proxy address and port explicitly. The http_proxy and https_proxy environment variables are being ignored otherwise.\r\n\r\n    def download_lattice_tgz(url)\r\n      uri = URI(url)\r\n    #  Net::HTTP.start(uri.host, uri.port, p_addr: \"proxy.pal.sap.corp\", p_port: 8080, use_ssl:   uri.scheme == 'https' ) do |http|\r\n       Net::HTTP.start(uri.host, uri.port, \"proxy\", 8080, use_ssl: uri.scheme == 'https' ) do    |http|\r\n\r\nI don't know Ruby that well so I'm not sure what's going on, but I found a hint here: https://www.jethrocarr.com/2014/08/14/ruby-nethttp-proxies/\r\n\r\n> Turns out that this proxy transversal only takes place if Net::HTTP is invoked as an object, however if you invoke one of it’s methods directly it ignores the proxy environmentals entirely.\r\n\r\nSo, with HTTP.start, the environment variables are being ignored and `vagrant up` fails like this:\r\n\r\n    Local lattice.tgz not found, downloading...\r\n    There was an error loading a Vagrantfile. The file being loaded\r\n    and the error message are shown below. This is usually caused by\r\n    a syntax error.\r\n\r\n    Path: C:/Users/i007509/lattice/lattice-bundle-v0.6.0/vagrant/Vagrantfile\r\n    Message: getaddrinfo: No such host is known.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/comments/151345057","html_url":"https://github.com/cloudfoundry-incubator/lattice-release/issues/226#issuecomment-151345057","issue_url":"https://api.github.com/repos/cloudfoundry-incubator/lattice-release/issues/226","id":151345057,"user":{"login":"davidwadden","id":9936700,"avatar_url":"https://avatars.githubusercontent.com/u/9936700?v=3","gravatar_id":"","url":"https://api.github.com/users/davidwadden","html_url":"https://github.com/davidwadden","followers_url":"https://api.github.com/users/davidwadden/followers","following_url":"https://api.github.com/users/davidwadden/following{/other_user}","gists_url":"https://api.github.com/users/davidwadden/gists{/gist_id}","starred_url":"https://api.github.com/users/davidwadden/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidwadden/subscriptions","organizations_url":"https://api.github.com/users/davidwadden/orgs","repos_url":"https://api.github.com/users/davidwadden/repos","events_url":"https://api.github.com/users/davidwadden/events{/privacy}","received_events_url":"https://api.github.com/users/davidwadden/received_events","type":"User","site_admin":false},"created_at":"2015-10-27T02:17:29Z","updated_at":"2015-10-27T02:17:29Z","body":"Thanks, that's definitely a possibility as we made our `Vagrantfile` work on Windows.  I've prioritized [[#106711812](https://www.pivotaltracker.com/story/show/106711812)] for the team to review, and we'll look into cutting a patch release soon as we can.\r\n\r\n@davidwadden"}}