easy-deploy-bundle icon indicating copy to clipboard operation
easy-deploy-bundle copied to clipboard

Permission denied

Open floran974 opened this issue 7 years ago • 3 comments

Hi,

when I try to execute php bin/console deploy,

I have this error :

' The command "(export SYMFONY_ENV=prod; cd /home/gbdd/SandBox/deploy-test && git ls-remote [email protected]:GBDD/AAA.git master)" failed.

Exit Code: 128(Invalid exit argument)

Working directory: /home/gbdd/SandBox/deploy-test

Permission denied (publickey).

fatal: Could not read from remote repository.'

But I think I have Permission because when I execute git ls-remote [email protected]:GBDD/AAA.git master on my console it's work.

Thank s for your help

floran974 avatar Apr 10 '18 14:04 floran974

Is the SSH key automatically loaded or do you have to add it to the ssh-agent manually? Is it password-protected for example?

YetiCGN avatar Jul 02 '18 15:07 YetiCGN

Maybe this is because hostname should be in known_hosts on server

dachinat avatar Sep 05 '18 23:09 dachinat

I may be pretty late, but you also have to be sure that you have an SSH agent running in your local machine and that you've added the key to it by using ssh-add command.

After many hours, that's what was causing my problem: The server and my local machine had the correct configuration with ForwardAgent and AllowAgentForwarding, I was using useSshAgentForwarding from the bundle and everything was right, but my ssh key was never forwarded because it was not running on an ssh agent.

Marcelo-Petrucelli avatar Jul 23 '19 14:07 Marcelo-Petrucelli