EC2

Supported operations

Operation
Permissions Required
Example Prompts

List vpcs

ec2:DescribeVpcs

list all the vpcs

list all the vpcs which are not default

Create vpc

ec2:CreateVpc

create a vpc with '10.101.0.0/16' cidr  

Delete vpc

ec2:DeleteVpc

delete a vpc with '<vpc_id>' id

List subnets

ec2:DescribeSubnets

list all the subnets

list all the subnets which are not default

list all the subnets under '<vpc_id>' vpc

Create subnet

ec2:CreateSubnet

create a subnet with '10.101.1.0/24' cidr under '<vpc_id>' id

Delete subnet

ec2:DeleteSubnet

delete a subnet with '<subnet_id>' id

List instances

ec2:DescribeInstances

list all the ec2 vms

Provision instances

ec2:RunInstances

Provision an ec2 vm with following details -
subnet id - <subnet id>
ami id - <ami id>
instance type - t2.micro
min count - 1
max count - 1

Start instances

ec2:StartInstances

Start ec2 vms with following ids -
<vm1 id>
<vm2 id>

Stop instances

ec2:StopInstances

Stop ec2 vms with following ids -
<vm1 id>
<vm2 id>

Describe instance types

ec2:DescribeInstanceTypes

list all the instance types which are free tier eligible

Last updated

Was this helpful?