PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Saturday, January 1, 2022

[FIXED] Laravel Nova installation via composer fails on production server

 January 01, 2022     composer-php, laravel, laravel-nova     No comments   

Issue

I have added Laravel Nova to our application and purchased a license. On the local server everything works perfectly. However, when I try to deploy the updated application to our linux server and run composer update it says:

Failed to download laravel/nova from dist: /var/www/{myPath} does not exist and could not be created.
    Now trying to download from source

Syncing laravel/nova (3.29.0) into cache

Cloning failed using an ssh key for authentication, enter your GitHub credentials to access private repos
Head to https://github.com/settings/tokens/new It will be stored in "/var/www/{myPath}"

So I created a GitHub Token and added the Laravel Nova credentials to the auth.json file on the server too. Everything should be correct and it is working on the local copy as I said before. However, I am getting the following errors:

[RuntimeException]                                                                                                                                    
Failed to execute git clone --mirror -- 'git@github.com:laravel/nova.git' '/var/www/{myPath}/.cache/composer/vcs/git-github.com-laravel-nova.git/'                                                                                                                                              
                                                                                                                                                        
Cloning into bare repository '/var/www/{myPath}/.cache/composer/vcs/git-github.com-laravel-nova.git'...                                     
ERROR: Repository not found.                                                                                                                          
fatal: Could not read from remote repository.                                                                                                         
                                                                                                                                                        
Please make sure you have the correct access rights                                                                                                   
and the repository exists.      

How could I solve this problem?


Solution

Deleting the /vendor directory and the composer.lock file and running composer install --optimize-autoloader --no-devsolved the problem.



Answered By - arety_
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing