How to use SSH keys with remote.it provided URL's

Hello,

I have set up remote.it for a few devices for personal use (Linux), device A and B. I have provisioned each of them with their own ed25519 keys, called Q and P.

I run SSH clients from both a windows and Linux computer, called C and D.

When using remote.it web client or the remote.it desktop app, I do not see any places to go in and provide the path to my ssh key for each device.

I have disabled password access over SSH to my devices for security reasons, and I also have a ~/.ssh/config file set up on my host computers C and D that works on the local network.

Is there any for me to configure the remote.it application to use my SSH keys for access, rather than the current behavior of password access, or a way to use a SSH config file?

As a workaround, I can manually copy the proxy address, port, and then the path to the key, but this is tedious and error prone.

We have an article about setting up connection configurations for your your services.
https://link.remote.it/support/connection-settings
You would use the template to add the -i option in your ssh command and then use the path to your key.

1 Like

Awesome this worked perfectly. Thanks for making that video.

1 Like

Follow up -

This works great for copying/pasting into a terminal, but some workflows prefer using a ssh config file.

For example, on Windows using VSCode, I can paste in this command into a terminal and it works great:

ssh ryan@ryan-b650-970-ssh.at.remote.it -p 33000 -i ~/.ssh/b650

However, in VSCode, this doesn’t work so well. It has a built in SSH extension, which you can connect to hosts you set up in your ~/.ssh/config file. Below, you can see the selection for some I have already set up.
image

If you want to connect to a manual entry, the same syntax does not work, because VSCode doesn’t allow adding options to user@host.

Currently, I get around this by quickly editing my ~/.ssh/config file, changing the port and proxy, while keeping the ssh key path the same.

I believe, it would be best, if remote.it actually wrote an ssh config entry when you create a connection.
I noticed when I installed the desktop version, it added this line to my ssh config:

Include C:\Users\ryan\AppData\Local\remoteit\ssh_config

This file does not exist though.

Would it be possible for remote.it to edit that file to maintain the connections as it sets them up and tears them down?

This would have the key advantage of easing integration with code editors and other ssh tools that already take advantage of the standarized ssh config format.

Thanks for the suggestion. I will put it into the queue to look at doing.

1 Like