Connecting to PostgreSQL
Manage Connectionsin the top center of the app.
New Connectionin the
Manage Connectionsmodal in PopSQL.
Nickname, enter something a descriptive name for your connection, like
Hostname, enter the hostname of your database server.
Port, use the default
5432, or enter the port used by your server.
Database, enter the name of your database.
Password, enter the username and password for PostgreSQL. These are optional.
Connectand you're all set!
Happy querying! 🍭
AWS RDS IAM
Once enabled, you will be able to select "Amazon RDS IAM Credentials" or "Amazon RDS IAM Profile" as the connection method for PostgreSQL. When using the credentials method, you will be asked for the
AWS Access Key ID,
AWS Secret Access Key, and optionally the
AWS Session Token, which should provided by your administrator. For the profile method, you will be asked for your
Profile which corresponds to the named profile you have configured within the AWS CLI.
For both methods, you will also be asked for a
Username corresponds to the DB user you wish to use to connect to the database. This user should be granted the
rds_iam permission within the database. For example, to create a new user for IAM, you would do the following:
-- Create a new database user CREATE USER iam_user; -- Grant permission to use RDS IAM to that user GRANT rds_iam TO iam_user;
This authentication mechanism only works with direct connections, so please make sure your computer can reach RDS (i.e. you may need to configure need to configure the RDS VPC to allow your IP address).
Spread the wordTweet