Security group rules can be imported to security groups. You can export the rules of a security group to a file, and then import the file to other security groups or the original security group to create or restore security group rules in a quick and easy manner.
You can choose Export > JSON Format or Export > CSV Format on the Security Group Rules page of a security group to download and save the security group rules to a local JSON or CSV file. You can modify the JSON or CSV file and add custom security group rules in the required format.
- Log on to the ECS console.
- In the left-side navigation pane, choose .
- In the top navigation bar, select a region.
- On the Security Groups page, find the security group to which you want to import rules and click Add Rules in the Actions column.
- In the Access Rule section of the Security Group Rules page, click Import Security Group Rule.
- In the Import Security Group Rule dialog box, click Select a file and then select the local JSON or CSV file that you want to import. The dialog box provides a preview of the rules in the file. The following information about the rules is displayed:
Note You can import a maximum of 200 security group rules to a security group. Newly imported rules do not overwrite existing rules. When the maximum number of rules in the security group is reached, excess rules are not imported to the security group.
- The result of the import check. If a rule fails the import check, you can move the pointer over the warning icon for details.
- Details of the rules.
- Click Start.