1

I would like to deploy my app onto a Cloudfoundry node. Using composer for dependency management.

Now there is one repository with private packages, which is secured by basic auth (Example https://composer.example.com).

"repositories": [{
  "type": "composer",
  "url": "https://composer.example.com"
}]

By default, i'm using a auth.json with the needed credentials, and composer would use it.

{
    "http-basic": {
        "composer.example.com": {
            "username": "max",
            "password": "mustermann"
        }
    }
}

But, pushing my app to a Cloudfoundry node, composer gets executed and will fail when it comes to include the private packages.

The 'https://composer.example.com/the/package-1.7.3.zip' URL required authentication. You must be using the interactive console to authenticate

Updating my dependencies locally works like a charm, deploying my app with capistrano for exmple, works as well. But cloudfoundry in some way does not recognize the auth.json.

Any hint or help would be much appreciated.

Paschi
  • 11
  • 1
  • Can you open a github issue against the PHP buildpack? I'm pretty sure there's a bug here which is causing composer to not see your auth.json file. https://github.com/cloudfoundry/php-buildpack – Daniel Mikusa Mar 23 '18 at 17:26
  • 2
    @DanielMikusa seems that you're right. Somehow the composer.json and composer.lock files get moved into the root, but the auth.json not. So composer can't see that file... Will open a issue there. Thx. – Paschi Mar 27 '18 at 08:31

0 Answers0