

In our example, we will connect to the Bastion host over SSH and then through that Bastion host we will create a SSH tunnel from our local ports to the remote EC2/RDS machines. The SSH tunnel created by PuTTY will forward data sent to these local ports to the remote IP/port and then return back the response. An SSH tunnel is a way to create a secure connection from a local computer to a remote one over a SSH connection done by mapping a local port on your machine to a remote IP address/port combination. To connect to EC2/RDS machines, you will use a concept called SSH tunneling.
#SSH TUNNEL PGADMIN 4 WINDOWS#

#SSH TUNNEL PGADMIN 4 HOW TO#
Not only will this article show you how to create a SSH terminal connection to an EC2 machine, but also show you how you can setup pgAdmin to connect and administer a RDS hosted PostgreSQL database without having to expose the RDS instance on a public subnet! Pre-requisites: In this post, I will quickly walk through the steps necessary to create the SSH tunnels necessary to access an EC2 machine and a RDS database sitting on internal subnets in AWS from a Windows terminal using the PuTTY tool (henceforth referred to simply as “Putty”). Accessing AWS resources, such as a Linux EC2 machine or a PostgreSQL database hosted on RDS, from your local development machine can be a little bit tricky, since these resources are generally recommended not to be exposed to the Internet and involves a technique called SSH tunneling.
