Get started with Amazon Redshift on LocalStack

Redshift is a cloud-based data warehouse solution which allows end users to aggregate huge volumes of data & parallel processing of data. Redshift is fully managed by AWS and serves as a petabyte-scale service which allows users to create visualization reports and critically analyze collected data. The query results can be saved to an S3 Data Lake while additional analytics can be provided by Athena or SageMaker.

A basic version of Redshift is available in LocalStack Pro - see the supported APIs are available over our feature coverage page.

Getting started

In this getting started guide, you’ll learn how to make a basic usage of Redshift over LocalStack. This guide is intended for users who wish to get more acquainted with SNS, and assumes you have basic knowledge of the AWS CLI (and our awslocal wrapper script). First, start your LocalStack instance using your preferred method, then run the following commands:

  1. Create a cluster named mysamplecluster using the awslocal CLI:

    $ awslocal redshift create-cluster --cluster-identifier mysamplecluster --master-username masteruser --master-user-password secret1 --node-type ds2.xlarge --cluster-type single-node

  2. Check the Redshift cluster creation progress by running the following command:

    $ awslocal redshift describe-clusters --cluster-identifier mysamplecluster

  3. Get all the information about all cluster security groups in the account:

    $ awslocal redshift describe-cluster-security-groups

  4. Get all the general cluster properties:

    $ awslocal redshift describe-clusters

  5. Associate a cluster with a cluster security group:

    $ awslocal redshift modify-cluster --cluster-identifier mysamplecluster --cluster-security-groups mysamplesecuritygroup

  6. Delete a cluster without specifying a final snapshot:

    $ awslocal redshift delete-cluster --cluster-identifier mysamplecluster --skip-final-cluster-snapshot

To get started with a more extensive example, please refer to the Glue Crawler Redshift Integration (JDBC) sample project.