Redpanda Cloud Quickstart
Spin up a Redpanda cluster with Redpanda Cloud, create a basic streaming application using the rpk command-line tool, and explore your cluster in Redpanda Console.
Redpanda Cloud is a fully managed Redpanda cluster hosted on dedicated resources and configurable instance types.
Prerequisites
Sign up for a trial of Redpanda Cloud - Dedicated Clusters.
Deploy Redpanda
To deploy a Redpanda cluster in the Dedicated cloud, create a namespace, then follow the steps for creating a Dedicated cluster.
To create a namespace:
-
Go to Redpanda Cloud and click Log in.
-
Enter your organization name, and click Continue.
-
Click Add namespace.
Namespaces help you organize clusters by owner, team, or project for example.
-
Enter a name for your namespace, and click Create.
To create a cluster:
-
Click Add Cluster.
-
Click Create Dedicated cluster, and enter the following values:
-
Cluster name:
redpandaquickstart
-
Throughput: 1 MBps
-
Version: Choose the latest available version
-
-
Click Next to see the Cloud settings options, and enter the following values:
-
Provider: AWS
-
Region: Any region that’s closest to you
-
Availability: Single AZ
-
Select a zone: Choose any zone
-
-
Click Next to see the Networking options, and enter the following values:
-
Connection Type: Public Network
-
-
Click Create.
-
Wait for both your network and your cluster to be created.
Start streaming
To start building a basic streaming application, you can use rpk to create a topic, produce messages to it, and consume messages from it. rpk is a command-line tool for connecting to and interacting with Redpanda brokers.
-
Install rpk on your local machine:
The rpk
binary is not supported on Windows.-
Linux
-
macOS
-
Download the
rpk
archive for Linux, and make sure the version matches your Redpanda version.-
To download the latest version of
rpk
:curl -LO https://github.com/redpanda-data/redpanda/releases/latest/download/rpk-linux-amd64.zip
-
To download a version other than the latest:
curl -LO https://github.com/redpanda-data/redpanda/releases/download/v<version>/rpk-linux-amd64.zip
-
-
Ensure that you have the folder
~/.local/bin
:mkdir -p ~/.local/bin
-
Add it to your
$PATH
:export PATH="~/.local/bin:$PATH"
-
Unzip the
rpk
files to your~/.local/bin/
directory:unzip rpk-linux-amd64.zip -d ~/.local/bin/
-
Run
rpk version
to display the version of the rpk binary:rpk version
23.2.8 (rev 2f0de10)
-
If you don’t have Homebrew installed, install it.
-
Install rpk:
brew install redpanda-data/tap/redpanda
-
Run
rpk version
to display the version of the rpk binary:rpk version
23.2.8 (rev 2f0de10)
This method installs the latest version of rpk
, which is supported only with the latest version of Redpanda.
-
-
On the Overview page of Redpanda Cloud, copy your bootstrap server address and set it as an environment variable on your local machine:
export RPK_BROKERS="<bootstrap-server-address>"
-
In Redpanda Cloud, go to Security and create a user called redpanda-chat-account that uses the SCRAM-SHA-256 mechanism.
-
Copy the password, and set the following environment variables on your local machine:
export REDPANDA_SASL_USERNAME="redpanda-chat-account" export REDPANDA_SASL_PASSWORD="<password>" export REDPANDA_SASL_MECHANISM="SCRAM-SHA-256"
-
In Redpanda Cloud, click the name of your user and add the following permissions to the ACL (access control list):
-
Host: *
-
Topic name:
chat-room
-
Operations: All
-
-
Use rpk on your local machine to authenticate to Redpanda as the redpanda-chat-account user and get information about the cluster:
rpk cluster info --tls-enabled
-
Create a topic called
chat-room
.You granted permissions to the redpanda-chat-account user to access only this topic.
rpk topic create chat-room --tls-enabled
Output:
TOPIC STATUS chat-room OK
-
Produce a message to the topic:
rpk topic produce chat-room --tls-enabled
-
Enter a message, then press Enter:
Pandas are fabulous!
Example output:
Produced to partition 0 at offset 0 with timestamp 1663282629789.
-
Press Ctrl+C to finish producing messages to the topic.
-
Consume one message from the topic:
docker exec -it redpanda-0 rpk topic consume chat-room --num 1
Your message is displayed along with its metadata:
{ "topic": "chat-room", "value": "Pandas are fabulous!", "timestamp": 1663282629789, "partition": 0, "offset": 0 }
Explore your topic
In Redpanda Cloud, go to Topics > chat-room.
The message that you produced to the topic is displayed along with some other details about the topic.
Clean up
If you don’t want to continue experimenting with your cluster, you can delete it.
Go to Cluster settings and click Delete cluster.