M
M
magary42015-05-14 12:57:21
git
magary4, 2015-05-14 12:57:21

Can't push to amazon?

I can ssh into my amazon machine like this ssh -i mykey.pem [email protected]
when I try to git push to this server it gives Permission denied (publickey).
googled added .ssh/config
Host Amazon
HostName 52.24.245.111
User ec2-user
IdentityFile ~/.ssh/mykey.pem
but that didn't help

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
D', 2015-05-14
@magary4

Faced such a problem.
I use:

$ eval "$(ssh-agent -s)"
$ ssh-add /path/to/private/key
$ git push ...

Should help.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question