SSH Access - cat-box/aws-foundry-ssl GitHub Wiki

⚠️ Advanced Users Only ⚠️

If you are using this section, I expect that you are at the very least somewhat familiar with linux and it's basic components.

Port 22

You will have to first open port 22 in the AWS security group. Please refer to Opening Port 22 for how to do so.

EC2 Instance IP

You will also need your server's IP address. If you're unsure of how to find this, please refer to EC2 Instance IP.

Windows

The easiest way to SSH into your server via Windows is to use PuTTY. This is recommended by AWS and is my personal preference on Windows machines.

Installation

  1. Download the PuTTY Installer.
    More than likely you will want the 64-bit MSI installer, but if you are running a 32bit system, please install that one instead.
  2. Run the Installer and leave everything on default.
  3. Launch PuTTY when finished.

Convert .pem to .ppk

You will need to convert your AWS key pair to .ppk format since PuTTY doesn't natively support .pem format. Good thing for us, PuTTY also includes a key converter tool.

  1. Launch PuTTYgen
  2. Click Load
    Load Keys
  3. In the bottom right corner, change to All Files (*.*)
    All Files (*.*)
  4. Open the SSH Key Pair you generated from AWS and used during setup
  5. You will see a PuTTYgen Notice if it successfully imported the key, click OK
    Success Message
  6. Click Save Private Key
  7. It will warn you that a passphrase has not been assigned, click Yes
  8. Choose a place to save the key. I recommend keeping it together with your .pem file from Amazon

You now have a .ppk key pair!

Setup

  1. Launch PuTTY
  2. On the left, navigate to the Auth menu via Connection -> SSH -> Auth
    Auth Settings
  3. Click Browse and select the converted .ppk key
    Browse AWS Key Pair
  4. Navigate back to the Session menu
  5. Enter the following in the fields
    Host Name (or IP address): ec2-user@<ec2 ip address here>           e.g. [email protected]
    Port: 22
    Connection type: SSH
    Saved Sessions: Foundry AWS
    
  6. Click Save
    You will now be able to load your changed settings in without having to manually click through the steps above.
  7. Click Open to connect to the ec2 instance.
  8. Click Yes
    Add Host Key

You should now be connected via SSH.

Mac

Mac OS is a unix based system and already natively supports SSH.

  1. Determine where your aws key pair file is and have it handy
  2. Open the terminal application
  3. Type the following into the terminal ssh -i <path to aws key pair file here> ec2-user@<ip address here>
    The resulting command should look similar to so: ssh -i ~/awskeypair.pem [email protected]
  4. Type yes if prompted and hit the enter/return key
⚠️ **GitHub.com Fallback** ⚠️