Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Pixelairport's avatar

Install Nova on Forge with Composer

Hi. I try to install Nova on Forge, but I get an error and the information:

Please make sure you have the correct access rights and the repository exists.

I think the best links I found are:

This is from the second link: For forge the credentials are actually saved within /home/forge/.composer/auth.json

I want to create this auth.json via command tool in forge. Is that possible? I already did:

composer config http-basic.nova.laravel [email protected] fxne-MY-API-TOKEN-FROM-NOVA-ldsknwe

Does anybody can help with that? I would prefer to set credentials in my project instead of having them in my github repo.

thx

0 likes
10 replies
Pixelairport's avatar

PS: Maybe there is a better way? Because also my Tests on Github Actions fail. Do I have to make it another way?

Pixelairport's avatar

Ok... i did some other tests and found out that the api token not work like the nova docs say. I cant replace password with token. I put my file in the same directory like composer on my local homestead than do composer install and it works. If i replace the password with the token it dont... i will go on testing, but still hope for tipps here. thx

Pixelairport's avatar

Ok. For all with same problem... auth.json must be placed in main directory of your project. The same where also the main composer.json file is. The file must be look like that:

{
    "http-basic": {
        "nova.laravel.com": {
            "username": "MY_EMAIL_USERNAME",
            "password": "MY_API_TOKEN_FROM_NOVAa"
        }
    }
}

I now created a ssh user in forge and realised that we used nova.laravel instead of nova.laravel.com.

LAST QUESTION: Would you save this auth.json within your project and store the file to github? I think this would also be the solution for the problems in Github Actions. Or is that also not allowed from Nova Licence?

1 like
robertosantana's avatar

@Pixelairport Hello, same problem here. I've tried your solution but it doesn't work for me. I think is because the deployment deletes all the content in the folder. Any idea?

KristianJust's avatar

@robertosantana Allow me to rewrite / dumb it down a bit here:

  1. ssh into the server
  2. sudo su forge
  3. composer config --global http-basic.nova.laravel.com [email protected] your-license-key
  4. Install application from Forge controlpanel
1 like
colourmill's avatar

Don't know whether this is a recent addition but you can add your composer credentials under packages in Laravel Forge.

1 like
jhull's avatar

Update: when adding to packages, use you License Key in Nova dashboard as PW (not PW for Nova)

yoman's avatar

Here is how I solve it depend is it a fresh laravel project on Forge or existing one

For fresh laravel project on Forge,

1 like

Please or to participate in this conversation.