Updated on 2023-07-20 GMT+08:00

Preparing the Environment

Before creating RabbitMQ instances, you must create a VPC and configure security groups and subnets for it. A VPC creates an isolated virtual network environment for you to configure and manage RabbitMQ instances, improving resource security and simplifying network deployment.

Once you have created a VPC, you can use it for all instances you subsequently create.

Creating a VPC

  1. Log in to the management console.
  2. In the upper left corner, click and select a region.

    Select the region where your RabbitMQ instance is.

  3. Click and choose Networking > Virtual Private Cloud.
  4. Click Create VPC.
  5. Create a VPC as prompted, For details on how to create a VPC, see the Virtual Private Cloud User Guide.

    After a VPC is created, a subnet is also created. If the VPC needs more subnets, go to 6. Otherwise, go to 7.

  6. In the navigation pane, choose Subnets. Click Create Subnet. Create a subnet as prompted,

    For details on how to create a subnet, see the Virtual Private Cloud User Guide.

  7. In the navigation pane, choose Access Control > Security Groups. Create a security group as prompted,

    For details on how to create a security group, see the Virtual Private Cloud User Guide.

    To use RabbitMQ instances, add the security group rules described in Table 1. Other rules can be added based on site requirements.

    After a security group is created, its default inbound rule allows communication among ECSs within the security group and its default outbound rule allows all outbound traffic. In this case, you can access a RabbitMQ instance within a VPC, and do not need to add rules according to Table 1.

    Table 1 Security group rules

    Direction

    Protocol

    Port

    Source

    Description

    Inbound

    TCP

    5672

    0.0.0.0/0

    Access a RabbitMQ instance (without SSL encryption).

    Inbound

    TCP

    5671

    0.0.0.0/0

    Access a RabbitMQ instance (with SSL encryption).

    Inbound

    TCP

    15672

    0.0.0.0/0

    Access the management UI (without SSL encryption).

    Inbound

    TCP

    15671

    0.0.0.0/0

    Access the management UI (with SSL encryption).