5 years ago

Laravel 5 SSH into Forge with Public SSH Key - Permission denied (publickey).

Posted 5 years ago by penguinfeet

Hi guys,

I am trying to follow along with the Laracast here and connect to my DB on a Larave 5 project using Forge:

However, I am running into trouble. No matter what I've done, I run into the error:

Permission denied (publickey).

I have tried creating a public SSH key on my machine using:

ssh-keygen -t rsa -C ""

I save it like so:


which generates an identification: somekey and a public key:

Then I use the command:

cat ~/.ssh/| pbcopy

to copy the key and then I put it in my SSH keys on my server in forge.

However, when I use the command: ssh forge@forge_ip_address

I get the same error: Permission denied (publickey).

Is there something I can do? Thank you!

Please sign in or create an account to participate in this conversation.