Skip to content
This repository has been archived by the owner on Jun 5, 2020. It is now read-only.

Latest commit

 

History

History
53 lines (41 loc) · 4.39 KB

aws_security_group.md

File metadata and controls

53 lines (41 loc) · 4.39 KB

Document: "ec2"

Path: "https://github.com/aws/aws-sdk-go-v2/tree/master/models/apis/ec2/2016-11-15/api-2.json")

SecurityGroup

aws_security_group {
  description => "description (optional)",
  dry_run => "DryRun (optional)",
  filters => "Filters (optional)",
  group_id => "group_id (optional)",
  group_ids => "GroupIds (optional)",
  group_name => "group_name (optional)",
  group_names => "GroupNames (optional)",
  max_results => "1234 (optional)",
  group_name => "group_name (optional)",
  next_token => "next_token (optional)",
  vpc_id => "vpc_id (optional)",
}
Name Type Required
description String false
dry_run Boolean false
filters FilterList false
group_id String false
group_ids GroupIdStringList false
group_name String false
group_names GroupNameStringList false
max_results Integer false
group_name String false
next_token String false
vpc_id String false

CRUD operations

Here is a list of endpoints that we use to create, read, update and delete the SecurityGroup

Operation Path Verb Description OperationID
Create / POST

Creates a security group.

A security group is for use with instances either in the EC2-Classic platform or in a specific VPC. For more information, see Amazon EC2 Security Groups in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

EC2-Classic: You can have up to 500 security groups.

EC2-VPC: You can create up to 500 security groups per VPC.

When you create a security group, you specify a friendly name of your choice. You can have a security group for use in EC2-Classic with the same name as a security group for use in a VPC. However, you can't have two security groups for use in EC2-Classic with the same name or two security groups for use in a VPC with the same name.

You have a default security group for use in EC2-Classic and a default security group for use in your VPC. If you don't specify a security group when you launch an instance, the instance is launched into the appropriate default security group. A default security group includes a default rule that grants instances unrestricted network access to each other.

You can add or remove rules from your security groups using AuthorizeSecurityGroupIngress, AuthorizeSecurityGroupEgress, RevokeSecurityGroupIngress, and RevokeSecurityGroupEgress.

CreateSecurityGroup
List - list all / POST

Describes one or more of your security groups.

A security group is for use with instances either in the EC2-Classic platform or in a specific VPC. For more information, see Amazon EC2 Security Groups in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

DescribeSecurityGroups
List - get one ``
List - get list using params / POST

Describes one or more of your security groups.

A security group is for use with instances either in the EC2-Classic platform or in a specific VPC. For more information, see Amazon EC2 Security Groups in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

DescribeSecurityGroups
Update ``
Delete / POST

Deletes a security group.

If you attempt to delete a security group that is associated with an instance, or is referenced by another security group, the operation fails with InvalidGroup.InUse in EC2-Classic or DependencyViolation in EC2-VPC.

DeleteSecurityGroup