Connect to Redshift or Postgres
The following instructions apply to both Redshift and Postgres connections. Databases that are wire compatible with Postgres such as Cockroach Database (CRDB) will also work with these steps using Postgres connection type.
Summary of Content
Requirements
Connect to your Redshift Cluster
Locate your Redshift Cluster Credentials
Related Resources
Requirements
- Admin privileges in your Sigma organization. Learn about account types.
- A Redshift data warehouse
- A configured Redshift cluster
Configure Redshift
Follow the steps below to configure Redshift to connect to Sigma.
- Go to Elastic IP’s in the EC2 Console.
- Create an Elastic IP Address, this is required to make an IP address publicly accessible.
- Click Allocate Elastic IP address.
- Click Allocate.
- Go back to your Redshift Cluster and click Actions.
- Click Modify publicly accessible setting.
- Click Enable and select the Elastic IP address you created in the Elastic IP Address dropdown.
- Go to Security Groups in the EC2 Console.
- On the Create security group page, name and describe the security groups.
Note: a VPC is an elastic network that's populated by infrastructure, platform, and application services that share common security and interconnection.
- Add Sigma’s IP addresses to both the Inbound and Outbound rules.
GCP Sigma hosting : 104.197.169.18, 104.197.193.23
AWS Sigma hosting: 44.229.241.60, 54.188.54.135 - Return to your Redshift Cluster and click the Properties tab. Click Edit on the Network and security settings tab.
- Select the VPC Security Group you created and click Save Changes.
Data Permissions
If don’t want to use an existing Redshift user, create a new user for Sigma. If you want to leverage write access, create a schema for Sigma and grant all privileges to your user on that schema. Be sure to Grant usage on all schemas and Grant select on all tables you wish to access in Sigma
create user sigma_user password ‘123’ create schema sigma_write; grant all privileges on schema sigma_write to sigma_user; grant usage on schema public to sigma_user; grant select on all tables in schema public to sigma_user;
Obtain Connection Info and Establish Connection
Obtain the endpoint from the General Information section of your Redshift Cluster, this will go in the “Host” field in Sigma
Required Info:
- Host: Endpoint from above
- Port: 5439
- User: Your Redshift User
- Password: PW for above user
- Database:
- Enable TLS: Turn on if you wish to use TLS encryption
- Write Schema: Schema created in Redshift in previous step
Connect to your Redshift Cluster
- Open your Admin Portal by selecting Administration in the user menu at the top right of your screen.
- Select the Connections page from the left-hand panel.
- Click the Create Connection button.
- Name your connection.
- Select Redshift under warehouse Type.
Once selected, you're prompted to define your Connection Credentials.
Learn more about finding these credentials. - Enter your cluster Endpoint URL In the Host field.
Example:cluster.abcd.us-west-1.redshift.amazonaws.com
Note: Sigma will connect from 44.229.241.60, 104.197.169.18, 104.197.193.23, and 54.188.54.135. - Enter your cluster’s port number in the Port field.
- Enter your Redshift username in the User field.
- Enter your Redshift password in the Password field.
- Enter your cluster’s database name in the Database field.
- [optional] Enable TLS encryption on your connection.
- [optional] Connect to your instance via SSH Tunnel.
If you enable the SSH Tunnel, you're prompted to enter the Tunnel host and Tunnel port.
Learn more about configuring a SSH Tunnel.
- [optional] Under Connection Features, you can set a connection timeout and/or enable write access.
- Click Create in the top right to create your configuration.
Locate your Redshift Cluster Credentials
- Go to the AWS Management Console.
- In the search bar, search and select Redshift.
You're directed to the Redshift dashboard. - In the left-hand navigation panel, select Clusters.
- Click on the cluster you would like to connect to Sigma.
This directs you to the cluster page where you can find the required credentials to connect to Sigma.