Create Node Group
To communicate with the Stream Manager 2.0 API, you can use the integrated Swagger UI, Postman, or curl from the command line.
Stream Manager 2.0 include OpenAPI/Swagger UI by default, you can find it on the main Stream Manager 2.0 web page https://<STREAM_MANAGER_DOMAIN_NAME>
or using direct url: https://<STREAM_MANAGER_DOMAIN_NAME>/swagger-ui/index.html
If you are using Stream Manager 2.0 without an SSL certificate and domain name, use
http://<STREAM_MANAGER_IP_ADDRESS>
instead.
Documentation: Stream Manager 2.0 API Overview.
Get JWT Token
JWT token is used to authenticate and authorize users, ensuring secure access to the API.
- First example using username and password in the URL:
Please do not use this example if you have special characters like
@
in your R5AS_AUTH_USER or R5AS_AUTH_PASS variables.
- Second example using Base64 encoding for your username and password:
In this example, you need to replace <USER_AND_PASSWORD_IN_BASE64>
with your Base64-encoded username and password. To generate this encoded string, combine your username and password in the format username:password
, then encode this string using Base64. You can use the following command to encode it:
-
R5AS_AUTH_USER
– Authentication user name used to get JWT token. You set this secret in the.env
file during the configuration of Stream Manager 2.0. -
R5AS_AUTH_PASS
– Authentication user password used to get JWT token. You set this secret in the.env
file during the configuration of Stream Manager 2.0. -
Response body
Create Node Group Config
Creating a new node group will immediately begin scaling out Red5 Pro nodes using your configuration.
Json node-group-create.json
body:
Please replace these variables with the values you recorded in the previous steps:
NODE_GROUP_NAME
– The name of node group. Min 1 char, max 16 chars. Alphanumeric, plus -, _, and .. Must be GLOBALLY unique (no two Node Groups can share the same name) Example:node-group-test
SUB_GROUP_NAME
– The name of this SubGroup. Min 1 char, max 16 chars. Example:sub-group-test
NODE_VPC_NAME
– The name of the VPC you created when setting up the network (VPC). Example:red5pro-autoscaling
NODE_SECURITY_GROUP
– The name of the security group for Red5 Pro nodes, created during the network (VPC) setup. Example:red5pro-autoscaling-node-sg
NODE_IMAGE_NAME
– The name of the Red5 Pro node instance image you created when preparing the Red5 Pro node image. Example:red5pro-autoscaling-node-image
NODE_AWS_REGION
– The AWS region where you deployed your Stream Manager. This is the region where the Stream Manager will create autoscaling Red5 Pro nodes. Example:us-west-1
.NODE_INSTANCE_TYPE
– AWS instance type (Instance Type). Example:c5.large
(2 CPUs and 4GB of memory)- Follow the docs for instance types details.
Examples:
NODE_INSTANCE_TYPE | Category | CPUs | GB memory |
---|---|---|---|
c5.large | Compute Optimized | 2 | 4 |
c5.xlarge | Compute Optimized | 4 | 8 |
c5.2xlarge | Compute Optimized | 8 | 16 |
c5.4xlarge | Compute Optimized | 16 | 32 |
This example node group config will create 2 Red5 Pro node instances (origin and edge)
Get node group lists
- Response body
Delete node group
Debug page
Debug UI it is extra web application which can help with checking active node groups, streams, and more using UI interface.
Stream Manager 2.0 includes a Debug UI web page, which you can find on the main Stream Manager 2.0 web page at https://<STREAM_MANAGER_DOMAIN_NAME>
or directly at https://<STREAM_MANAGER_DOMAIN_NAME>/debug/
.