@penguinfeet have you added your SSH Key to the agent?
ssh-add ~/.ssh/id_rsa
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hi guys,
I am trying to follow along with the Laracast here and connect to my DB on a Larave 5 project using Forge:
https://laracasts.com/series/server-management-with-forge/episodes/4
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 "my_email@gmail.com"
I save it like so:
/Users/**********/.ssh/somekey
which generates an identification: somekey and a public key: somekey.pub
Then I use the command:
cat ~/.ssh/somekey.pub| 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 or to participate in this conversation.