I have a laravel app that I'm trying to deploy to Google Kubernetes with GitLab autodevops. When I trigger the CI pipeline it starts Herokuish PHP build and npm install, however, some of the composer repos are private. I understand that I need to add an environment variable named COMPOSER_AUTH that contains the content of auth.json that contains tokens to allow retrieving from the repos. But for some reason, the pipeline is always failing because it did not have permission to retrieve those repos. I know that the content of auth.json is correct because I tried it locally and it worked. I hope that someone helps me resolve this issue!
Here is what I have in the repo section in composer.json
"repositories": {
"nova" : {
"type": "composer",
"url": "https://nova.laravel.com"
}
}
For the COMPOSER_AUTH
variable, the content looks like this
'{
"gitlab-token":{
"gitlab.com": "GITLABTOKENHERE"
},
"http-basic": {
"nova.laravel.com": {
"username": "MY-EMAILI-HERE",
"password": "MY-NOVA-TOKEN-HERE"
}
}
}'
And this is some of the error message I get during npm install