Skip to content

Add an SSH key pair to your account

One of the first things to do in Rumble Cloud is to set up an SSH key pair.

When working with virtual machine (VM) instances in Rumble Cloud, you'll need to a way to access the virtual machines from your local computer. One common way to do this is by using an SSH key pair. A key pair is a set of public / private digital keys used to verify your identify. You store the private part of the key pair locally in a secure location, but you'll share the public part of the key pair. A key pair can be generated and stored on your local computer, and you can also use the cloud console interface to generate one.

SSH is an encryption protocol that enables secure communication between systems. You'll use an SSH client on your local computer to connect with a virtual machine.

Once you add a public key or create a key pair in Rumble Cloud, it is associated with your account and you can use it across different projects.

To learn more about using SSH, you can consult these or other Windows and macOS resources online:

For more information about key pairs, see the “Key Pairs” section in the "Cloud Console Guide".

Warning

SSH key pairs contain confidential authorization information. Do not share your private keys. Do store your private keys securely.

Upload your public key

Follow these instructions if your local computer uses macOS.

Key pairs are typically stored in the .ssh directory, which is a hidden directory on your computer.

You can access this directory from your /home/<user>/.ssh. If you’ve never created a key pair, the directory may not yet exist.

  1. Open the Terminal application on your computer.
  2. Go to the .ssh directory by typing:
    Bash
    cd .ssh
    ls
    

Look for the files id_ed25519 and id_ed25519.pub. If they don’t exist, go to the next step to create them.

Generate a key pair (macOS)

  1. Open the Terminal application.
  2. Go to the .ssh directory by typing:

    Bash
    cd .ssh
    

  3. Type the following in the terminal:

    Bash
    ssh-keygen -t ed25519
    

  4. When prompted, press 'Enter' instead of providing a file name.

  5. Optionally enter a passphrase to secure access to the key.
  6. A private key is written to /home/user/.ssh/id_ed25519 and a public key written to /home/user/.ssh/id_ed25519.pub. Type the following to confirm the files exist:

    Bash
    ls
    

  7. Type the following in the terminal.

    Bash
    ssh-add id_ed25519
    

Upload a public key (from macOS)

  1. In Rumble Cloud, select Compute > Key Pairs > Create Keypair.
  2. Select Import Keypair for the create type.
  3. For the name, use id_ed25519.
  4. Open the Terminal application on your computer.
  5. Type the following to copy the public key to your clipboard.

    Bash
    cat ~/.ssh/id_ed25519.pub | pbcopy
    

  6. In Rumble Cloud console, paste the public key into the Public Key field. Make sure to delete any trailing spaces after you paste the key. If the create operation fails, try again, look for trailing space, and remove it so the line ends with the last character of the key.

  7. Select OK to finish.

You'll now see the key pair in the dashboard. Your key pair is associated with your user account in Rumble Cloud, so you’ll be able to use it across projects.

Follow these instructions if your local computer uses Windows (10 or 11).

Generate a public key (Windows)

For detailed information, please read the documentation regarding SSH and key pairs from Microsoft: https://learn.microsoft.com/en-us/windows-server/administration/openssh/openssh_keymanagement

You'll can a tool such as OpenSSH on Windows. https://learn.microsoft.com/en-us/windows-server/administration/openssh/openssh_install_firstuse?tabs=gui

Key pairs are typically stored in the C:\ProgramData\ssh directory.

  1. Run the following command from an elevated PowerShell prompt on your local computer:

    PowerShell
    ssh-keygen -t ed25519
    

  2. You'll see the following (where 'username' is your Windows username):

    PowerShell
    Generating public/private ed25519 key pair.
    Enter file in which to save the key (C:\Users\username/.ssh/id_ed25519):
    

  3. Type 'Enter' to accept the default file name.

  4. You can optionally add a passphrase. You can leave it empty for this example.

  5. Look for the public key generated in the command line:

    PowerShell
    Enter passphrase (empty for no passphrase):
    Enter same passphrase again:
    Your identification has been saved in C:\Users\username/.ssh/id_ed25519.
    Your public key has been saved in C:\Users\username/.ssh/id_ed25519.pub.
    The key fingerprint is:
    SHA256:OIzc1yE7joL2Bzy8!gS0j8eGK7bYaH1FmF3sDuMeSj8 username@LOCAL-HOSTNAME
    
    The key's randomart image is:
    +--[ED25519 256]--+
    |        .        |
    |         o       |
    |    . + + .      |
    |   o B * = .     |
    |   o= B S .      |
    |   .=B O o       |
    |  + =+% o        |
    | *oo.O.E         |
    |+.o+=o. .        |
    +----[SHA256]-----+
    

  6. Copy the key fingerprint. You'll use the this value in the next step.

Upload a public key (Windows)

  1. In Rumble Cloud, select Compute > Key Pairs > Create Keypair.
  2. Select Import Keypair for the create type.
  3. For the name, use id_ed25519.
  4. In Rumble Cloud console, paste the public key into the Public Key field. Make sure to delete any trailing spaces after you paste the key. If the create operation fails, try again, look for trailing space, and remove it so the line ends with the last character of the key.
  5. Select OK to finish.

You'll now see the key pair in the dashboard. Your key pair is associated with your user account in Rumble Cloud, so you’ll be able to use it across projects.

Generate a key pair in the console

  1. In Rumble Cloud, select Compute > Key Pairs > Create Keypair.
  2. Select Create Keypair.
  3. Provide a name for the key pair.
  4. Click OK. The key pair <NAME>.pem file will download to your local computer. The .pem file contains your key pair as a certificate file.

If your local computer uses macOS, follow these instructions to use the key pair locally.

  1. Open the Terminal application.
  2. Go to the directory containing the downloaded .pem file.
  3. Type the following in the terminal.
    Bash
    ssh-add <NAME>.pem
    

Next steps

You can use different key pairs for different use cases. The key pairs will follow you across projects, so you don't need to generate new keys if you switch.

If you create a virtual machine, you'll be asked to provide a key pair as a part of the creation process. If you've followed the steps in this example, you'll have a key pair ready for use.

See also: