SSH and AWS LightSail

--

For a side project I need a simple server, so i choosed an AWS LightSail Linux Server. I installed the Amazon Linux distribution, then using the web ssh console, I installed MongoDB, Golang and other tools that I need. The problem is started when I have to move data on this server, using the command:

ssh -i mykey.pem ec2-usr@ipaddress

Give me this error:

Permission denied (publickey,gssapi-keyex,gssapi-with-mic).

In the end, I resolved to copy my local public ssh key in the .ssh/authorized_keys file on the server.

I wrote the key making a copy and paste using the web ssh console from the AWS LightSail console.

Honestly, I like the AWS product but in this case, I’m a bit disappointed because making what is wrote in the documentation don’t resolve the problem.

--

--