Error "406 Invalid" when trying to use Composer to set up a private repo

I am trying to set up PHP Composer dependency manager so that I can install a package from a private GitHub repository.

I followed the instructions using private repos for the test repo and I get a weird 406 error which is:

The requested resource is capable of generating content that is not acceptable according to the Accept headers sent in the request.

Error message:

$ composer install -n
Loading composer repositories with package information
Installing dependencies (including require-dev)
  - Installing growdigital/access (0.0.3)
    Downloading: connection...Failed to download growdigital/access from dist: The "https://github.com/growdigital/access/archive/0.0.3.zip" file could not be downloaded (HTTP/1.1 406 Not Acceptable)
Now trying to download from source
  - Installing growdigital/access (0.0.3)
Cloning 464c3a3a580ded3fdaf43a246388b6de33fbac89

      

This way it works with installation from source and not from zip. My question is actually how can I refer to the 406 error? Is there something I need to do to change the composer?

+3
git github php composer-php http-status-code-406


source to share


No one has answered this question yet

See similar questions:

17
How do I install the R package from a private repo using devtools install_github?

or similar:

273
Can pip be used to install a package from a private github repository?
68
Use PHP composer to clone git repo
4
Using Composer with Private GitHub Repositories over HTTPS
1
Composer is a private repo in a private repo
1
Installing ORO-CRM Composer - Failed to load composer / composer
1
Calls to "install composer" should only use satis dist zip files, never use
0
Composer does not clone git repo with preferred source
0
Secure Satisfactory Storage with Private Bitbucket Composers Repositories
0
Composer vcs installs (git repo) won't link to parent repo
-1
Error installing laravel 5 from author



All Articles
Loading...
X
Show
Funny
Dev
Pics