• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Question Composer in Plesk not working with github private branch in cmd it works

peterbinsje

New Pleskian
Server operating system version
Almalinux 8
Plesk version and microupdate number
latest
Using Composer via the command line works fine. I execute it with the command 'sudo -u <username> /opt/plesk/php/8.2/bin/php /usr/lib64/plesk-9.0/composer.phar install or update'. I can then input a token from github.com because I have a repository that I want to pull. However, when I try to do it through Plesk in the browser, it doesn't work, and I get a message saying that the credentials are not recognized! The strange thing is that after an hour or so, it suddenly starts working through Plesk in the browser! What could this be?"
 
Interesting. Can you post some detailed steps for me to follow so I can try to reproduce this issue?
 
I am receiving this notification in the Plesk browser when i click on composer install :

i change Myname and myrepo!

Failed to clone the [email protected]:Myname/myrepo.git repository, try running in interactive mode so that you can enter your GitHub credentials
In Git.php line 473:
Failed to execute git clone --mirror -- '[email protected]:Myname/myrepo.gi
t' '/.composer/cache/vcs/git-githu
b.com-Myname-myrepo.git/'
Cloning into bare repository '/.co
mposer/cache/vcs/git-github.com-Myname-myrepo.git'...
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
show [--all] [--locked] [-i|--installed] [-p|--platform] [-a|--available] [-s|--self] [-N|--name-only] [-P|--path] [-t|--tree] [-l|--latest] [-o|--outdated] [--ignore IGNORE] [-M|--major-only] [-m|--minor-only] [--patch-only] [-A|--sort-by-age] [-D|--direct] [--strict] [-f|--format FORMAT] [--no-dev] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--] [<package> [<version>]]


The strange thing is that after a while it does work! I've had the same experience on another server. I don't have a good feeling about it suddenly working after a while!
 
The Composer extension currently does not support any type of authentication which requires user input. If the composer install (or update) succeeded any I suspect is because the token got cached from comand line.
 
Back
Top