Wir verwenden für unser symfony Projekt neben den öffentlichen Quellen auch ein privates Repository auf unserem eigenen gitlab Server, der über ssh erreichbar ist.ubuntu: Wie installiere ich ein privates Repository mit Composer mit sudo
Wenn ich nur dieses private Repository auf meine lokale Ubuntu-Maschine klonen, ist alles in Ordnung. Wenn ich
$ sudo composer install
in dem Projekt, das dieses Repository umfasst ich folgende Fehlermeldung:
[RuntimeException]
Failed to execute git clone --mirror '[email protected]:myprivaterepo.git' '/home/aliebermann/.composer/cache/vcs/git-gitlab.con.example.com-myprivaterepo.git/'
Cloning into bare repository '/home/myuser/.composer/cache/vcs/git-gitlab.con.example.com-myprivaterepo.git'...
__________________________________________________________________
| |
| This system is for the use of authorized users only. Usage of |
| this system may be monitored and recorded by system personnel. |
| |
| Anyone using this system expressly consents to such monitoring |
| and is advised that if such monitoring reveals possible |
| evidence of criminal activity, system personnel may provide the |
| evidence from such monitoring to law enforcement officials. |
|__________________________________________________________________|
Permission denied (publickey,gssapi-keyex,gssapi-with-mic).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Ich nehme an, dies liegt daran, dass mein SSH-Schlüssel in meinem Privathaus befindet und wenn ich diese laufe Als Sudo werden sie nicht genannt. Da Sie "su" nicht einfach wie auf anderen Linux-Systemen verwenden können, weiß ich nicht, wie ich das beheben kann.
Let Composer laufen ohne Sudo funktioniert aber nicht.
Als nächstes kopierte ich all meinen SSH-Schlüssel /root/.ssh, aber da sie einem Passwort geschützt sind, laufe ich zum nächsten Problem in:
$ sudo ssh-add -k
[sudo] Password for myuser:
Could not open a connection to your authentication agent.
Ich habe die ganze Sache jetzt läuft als myuser ohne root. Das löst mein Problem, aber nicht die Frage. –