Tool for adding new ssh to config file

Usage no npm install needed!

<script type="module">
  import easyssh from 'https://cdn.skypack.dev/easyssh';



Simple NPM CLI tool for adding ssh credentials to your config file for easier access to your servers.


$ npm install -g easyssh

$ easyssh


Once you start easyssh, you will be asked to create a nickname for your server. This should be a short word or phrase that describes the server. It could be "dev" "production" "clientName" etc.

You will then be required to enter the HostName which is either the IP or name of vm your sshing into

Next you'll be prompted for the username

One of the easiest ways to ssh into a server is by creating a private key, then moving it to the authorized keys location on the server. To create a key enter the following in the terminal

ssh-keygen -t rsa

Once the key has been created, enter the following into the terminal with your credentials to move the private key to the server

cat ~/.ssh/id_rsa.pub | ssh user@hostname 'cat >> .ssh/authorized_keys'

If you do not have the ability to add the key to the server, skip this step, leave the following question blank and go to the next question. If you do have access, type or paste the key location such as the one above '~/.ssh/id_rsa.pub'

If you did not have access to the server and were just givin username & password or do not want to use the identity file, type yes in the following prompt.

In some cases you may need to specify which port to access the server. If so, enter the port into the following prompt, or leave blank if not necessary.

That's all. Now depending on what you used for a nickname for your server, type

$ ssh server-nickname

and you're in. If you followed the above steps and entered the information correctly you shouldn't have any problems. Future release of easyssh will allow for editing previously setup ssh configurations. If for some reason it doesn't work, type

$ vi ~/.ssh/config

and double check the information entered in your config file.