composer: File could not be downloaded behind a proxy
Hi,
I can’t download any git repos behind a proxy with composer since few days. Composer can update itselfs, but no other git repos.
For example:
$ php composer.phar create-project symfony/framework-standard-edition path/ 2.2.1
results in:
[Composer\Downloader\TransportException]
The "https://api.github.com/repos/symfony/symfony-standard/zipball/v2.2.1" file could not be downloaded (HTTP/1.0 500 Internal Server Error)
System configuration:
- configured enviroment
http_proxy
&https_proxy
- PHP 5.4.14
- Composer 81d55544f714cca03d5eb784d67a06f8148bcb15
The proxy configuration works fine (Mozilla, Thunderbird, …). Downloading the file with wget
or curl
works too:
$ wget https://api.github.com/repos/symfony/symfony-standard/zipball/v2.2.1
Any advice?
About this issue
- Original URL
- State: closed
- Created 11 years ago
- Comments: 25 (4 by maintainers)
Commits related to this issue
- Add HTTPS_PROXY_REQUEST_FULLURI to disable the request_fulluri only for https requests, fixes #1946, fixes #1839 — committed to digitalkaoz/composer by Seldaek 11 years ago
- HTTPS_PROXY_REQUEST_FULLURI=false for composer Unclear why this is all of a sudden needed; however, this seems to fix T182266. Found via: https://github.com/composer/composer/issues/1839 Bug: T18226... — committed to wikimedia/integration-zuul-config by thcipriani 7 years ago
@Seldaek after updating composer to it’s latest release and configuring:
HTTP_PROXY_REQUEST_FULLURI=true
(or unset)HTTPS_PROXY_REQUEST_FULLURI=false
it works like a charm here. Thanks!
I added a new HTTPS_PROXY_REQUEST_FULLURI since it seems some proxies are acting up really strange. Can you confirm that setting HTTPS_PROXY_REQUEST_FULLURI=false fixes it? It should disable it for HTTPS, but if you enable it (or just delete the env var) for HTTP then everything should work… Hopefully 😃
Configuring the
HTTP_PROXY_REQUEST_FULLURI
enviroment variable like:resolves the problem. Great!