Create an SSH key pair

Sometimes you may need to connect to your servers using an SSH client to run terminal commands on your remote server. An SSH public key is used for secure authentication when you use an SSH client to connect to a server managed by Devopness. When you connect, you must provide the private key that matches the public key added to the remote server. Create an SSH private/public key pair to securely authenticate your server access on the new device. Several tools exist to generate SSH public/private key pairs. The following steps show how to generate an SSH key pair on UNIX and UNIX-like platforms.

  1. On your local machine, in a terminal window, run the command below, replacing <your email address> with a valid email address
    ssh-keygen -t rsa -b 4096 -C "<your email address>"

    This creates a new SSH key, using the provided email as a label.

  2. Follow the prompts to complete the creation of the new SSH Key pair

    There should be 2 new files inside $USER/.ssh directory, id_rsa (private key) and id_rsa.pub (public key)

  3. To add the public key (id_rsa.pub) to Devopness, see Add an SSH key

Related: