Skip to main content
Red5 Pro provides official Terraform modules for deploying fully configured clusters on major cloud platforms. Terraform automates the provisioning of all required infrastructure — virtual machines, networking, security groups, and load balancers — so you get a reproducible, version-controlled deployment without manual cloud console work. A typical deployment provisions a Stream Manager plus a node group consisting of origin, edge, and relay nodes. The Stream Manager URL is printed as a Terraform output at the end of the apply step.
If you prefer a fully managed experience without operating your own infrastructure, consider Red5 Cloud, the hosted version of Red5 Pro.

Prerequisites

Before you begin, make sure you have:
  • Terraform (version 1.x or later) installed on your workstation. Download from developer.hashicorp.com/terraform.
  • Cloud provider credentials configured in your environment. For AWS this means an IAM user with programmatic access; for GCP a service account JSON key; for Azure a service principal.
  • A valid Red5 Pro license key from account.red5.net.
  • Sufficient cloud quota for the instance types you plan to use.

General Terraform workflow

Regardless of which cloud provider you target, the deployment process follows the same five steps:
1

Find the module on the Terraform Registry

All Red5 Pro modules are published at registry.terraform.io/modules/red5pro/red5pro. Each cloud provider has its own module with dedicated documentation.
2

Create a Terraform configuration file

Create a main.tf (or clone the example from the registry) and reference the module, then create a terraform.tfvars file with your specific values:
3

Initialize the working directory

This downloads the module and any provider plugins.
4

Preview the planned changes

Review the output to confirm the resources Terraform will create before you apply anything.
5

Apply and deploy

Type yes when prompted. Terraform provisions all resources and prints the Stream Manager URL when complete:
Store your Terraform state in a remote backend such as S3, GCS, or Terraform Cloud so that multiple team members can manage the same deployment safely.

Cloud provider modules

The AWS module deploys Red5 Pro into a VPC with an autoscaling node group managed by Stream Manager.Module: registry.terraform.io — AWSMinimum terraform.tfvars variables to configure:
Use the Ubuntu 22.04 AMI for all instances. The Amazon Linux AMI is not supported and may be missing libraries required by Red5 Pro.

What gets deployed

A complete Red5 Pro Terraform deployment provisions:
  • Stream Manager — orchestrates autoscaling and routes streams between nodes. Accessible via HTTPS on port 443.
  • Origin nodes — receive inbound streams from publishers.
  • Edge nodes — distribute streams to viewers, scaling horizontally as concurrent connections increase.
  • Relay nodes (optional) — bridge streams between geographic regions.
  • Security groups / firewall rules — opens the required ports for RTMP, WebRTC, and RTSP.

Tear down the deployment

To remove all provisioned resources:
terraform destroy permanently deletes all infrastructure created by the module, including any recorded stream data on the instances. Back up any data you need to keep before running this command.