ExAws.EC2 v2.0.1 ExAws.EC2 View Source

Operations on AWS EC2

A selection of the most common operations from the EC2 API are implemented here. http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_Operations.html

Examples of how to use this:

alias ExAws.EC2

EC2.terminate_instances(["i-123456", "i-987654"], [dry_run: true])
EC2.register_image("Test", [block_device_mappings: [
  [device_name: "/dev/sda1", ebs: [snapshot_id: "snap-1234567890abcdef0"]],
  [device_name: "/dev/sdb",  ebs: [snapshot_id: "snap-1234567890abcdef1"]],
  [device_name: "/dev/sdc",  ebs: [volume_size: 100]]
]])

Link to this section Summary

Types

Functions

Attaches a volume to a specified instance

Adds one or more egress rules to a security group for use with a VPC

Adds one or more ingress rules to a security group

Bundles an Amazon instance store-backed Windows instance. During bundling, only the root device volume (C:) is bundled. Data on other instance store volumes is not preserved

Cancels a bundling operation for an instance store-backed Windows instance

Initiates the copy of an AMI from the specified source region to the current region. You specify the destination region by using its endpoint when making the request

Copies a point-in-time snapshot of an EBS volume and stores it in Amazon S3. You can copy the snapshot within the same region or from one region to another

Creates an Amazon EBS-backed AMI from an Amazon EBS-backed instance that is either running or stopped

Creates a 2048-bit RSA key pair with the specified name. Amazon EC2 stores the public key and displays the private key for you to save to a file. The private key is returned as an unencrypted PEM encoded PKCS#8 private key

Creates a snapshot of an EBS volume and stores it in Amazon S3. You can use snapshots for backups, to make copies of EBS volumes, and to save data before shutting down an instance

Creates a subnet in an existing VPC

Adds or overwrites one or more tags for the specified Amazon EC2 resource or resources. Each resource can have a maximum of 10 tags. Each tag consists of a key and optional value. Tag keys must be unique per resource

Creates an EBS volume that can be attached to an instance in the same Availability Zone

Creates a VPC with the specified CIDR block

Deletes the specified key pair, by removing the public key from Amazon EC2

Deletes the specified snapshot

Deletes the specified subnet

Deletes the specified set of tags from the specified set of resources

Deletes a specified volume

Deletes the specified VPC

Deregisters the specified AMI. After you deregister an AMI, it can’t be used to launch new instances

Describes attributes of your AWS account

Describes one or more of the Availability Zones that are available to you. The results include zones only for the region you’re currently using

Describes one or more of your bundling tasks

Describes the ID format settings for your resources on a per-region basis, for example, to view which resource types are enabled for longer IDs

Describes the specified attribute of the specified AMI. You can specify only one attribute at a time

Describes one or more of the images (AMIs, AKIs, and ARIs) available to you

Describes the specified attribute of the specified instance. You can specify only one attribute at a time

Describes the status of one or more instances. By default, only running instances are described, unless specified otherwise

Describes one or more instances. If you specify the instance IDs or filters, Amazon EC2 returns information for those instances. If you do not specify an instance ID or filters, then it’ll all the relevant instances

Describes one or more of your key pairs

Describes one or more regions that are currently available to you

Describes one or more of your security groups

Describes the specified attribute of the specified snapshot. You can specify only one attribute at a time

Describes one or more of the EBS snapshots available to you

Describes one or more of your subnets

Describes one or more of the tags for your EC2 resources

Describes the specified attribute of the specified volume. You can specify only one attribute at a time

Describes the status of the specified volumes

Describes the specified EBS volumes

Describes the specified attribute of the specified VPC. You can specify only one attribute at a time

Describes one or more of your VPCs

Detaches a specific volume

Enables I/O operations for a volume that had I/O operations disabled because the data on the volume was potentially inconsistent

Gets the console output for the specified instance

Retrieves the encrypted administrator password for an instance running Windows

Imports the public key from an RSA key pair that you created with a third-party tool

Modifies the ID format for the specified resource on a per-region basis

Modifies the specified attribute of the specified AMI. You can specify only one attribute at a time

Modifies the specified attribute of the specified instance. You can specify only one attribute at a time

Adds or removes permission settings for the specified snapshot

Modifies a specified volume

Modifies the specified attribute of the specified VPC

Enables detailed monitoring for a running instance

Requests a reboot of one or more instances. This operation is asynchronous; it only queues a request to reboot the specified instances

Registers an AMI. When you’re creating an AMI, this is the final step you must complete before you can launch an instance from the AMI

Submits feedback about the status of an instance. The instance must be in the running state

Resets an attribute of an AMI to its default value. Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ResetImageAttribute.html

Resets an attribute of an instance to its default value. To reset the kernel or ramdisk, the instance must be in a stopped state. To reset the SourceDestCheck, the instance can be either running or stopped

Resets permission settings for the specified snapshot

Removes one or more egress rules from a security group for EC2-VPC

Removes one or more ingress rules from a security group. The values that you specify in the revoke request (for example, ports) must match the existing rule’s values for the rule to be removed

Launches the specified number of instances using an AMI for which you have permissions

Starts an Amazon EBS-backed AMI that was previously stopped

Stops an Amazon EBS-backed AMI that was previously started

Shuts down one or more instances. Terminated instances remain visible after termination (for approximately one hour)

Disables detailed monitoring for a running instance

Link to this section Types

Link to this type attach_volume_opts() View Source
attach_volume_opts() :: [{:dry_run, boolean()}]
Link to this type attribute_boolean_value() View Source
attribute_boolean_value() :: [{:value, boolean()}]
Link to this type attribute_value() View Source
attribute_value() :: [{:value, binary()}]
Link to this type authorize_security_group_egress_opts() View Source
authorize_security_group_egress_opts() :: [
  cidr_ip: binary(),
  dry_run: boolean(),
  from_port: integer(),
  ip_permissions: [ip_permission(), ...],
  ip_protocol: binary(),
  source_security_group_name: binary(),
  source_security_group_owner_id: binary(),
  to_port: integer()
]
Link to this type authorize_security_group_ingress_opts() View Source
authorize_security_group_ingress_opts() :: [
  cidr_ip: binary(),
  dry_run: boolean(),
  from_port: integer(),
  group_id: binary(),
  group_name: binary(),
  ip_permissions: [ip_permission(), ...],
  ip_protocol: binary(),
  source_security_group_name: binary(),
  source_security_group_owner_id: binary(),
  to_port: integer()
]
Link to this type block_device_mapping() View Source
block_device_mapping() :: [
  device_name: binary(),
  ebs: ebs(),
  no_device: binary(),
  virtual_name: binary()
]
Link to this type bundle_instance_opts() View Source
bundle_instance_opts() :: [{:dry_run, boolean()}]
Link to this type cancel_bundle_task_opts() View Source
cancel_bundle_task_opts() :: [{:dry_run, boolean()}]
Link to this type copy_image_opts() View Source
copy_image_opts() :: [
  client_token: binary(),
  description: binary(),
  dry_run: boolean(),
  encrypted: boolean(),
  kms_key_id: binary()
]
Link to this type copy_snapshot_opts() View Source
copy_snapshot_opts() :: [
  description: binary(),
  destination_region: binary(),
  dry_run: boolean(),
  encrypted: boolean(),
  kms_key_id: binary(),
  presigned_url: binary()
]
Link to this type create_image_opts() View Source
create_image_opts() :: [
  block_device_mappings: [block_device_mapping(), ...],
  description: binary(),
  dry_run: boolean(),
  no_reboot: boolean()
]
Link to this type create_key_pair_opts() View Source
create_key_pair_opts() :: [{:dry_run, boolean()}]
Link to this type create_security_group_opts() View Source
create_security_group_opts() :: [dry_run: boolean(), vpc_id: binary()]
Link to this type create_snapshot_opts() View Source
create_snapshot_opts() :: [description: binary(), dry_run: boolean()]
Link to this type create_subnet_opts() View Source
create_subnet_opts() :: [
  availability_zone: binary(),
  dry_run: boolean(),
  ipv6_cidr_block: binary()
]
Link to this type create_tags_opts() View Source
create_tags_opts() :: [{:dry_run, boolean()}]
Link to this type create_volume_opts() View Source
create_volume_opts() :: [
  dry_run: boolean(),
  encrypted: boolean(),
  iops: integer(),
  kms_key_id: binary(),
  size: integer(),
  snapshot_id: binary(),
  tag_specifications: [tag_specification(), ...],
  volume_type: binary()
]
Link to this type create_vpc_opts() View Source
create_vpc_opts() :: [
  dry_run: boolean(),
  instance_tenancy: binary(),
  amazon_provided_ipv6_cidr_block: boolean()
]
Link to this type delete_key_pair_opts() View Source
delete_key_pair_opts() :: [{:dry_run, boolean()}]
Link to this type delete_snapshot_opts() View Source
delete_snapshot_opts() :: [{:dry_run, boolean()}]
Link to this type delete_subnet_opts() View Source
delete_subnet_opts() :: [{:dry_run, boolean()}]
Link to this type delete_tags_opts() View Source
delete_tags_opts() :: [dry_run: boolean(), tags: [tag(), ...]]
Link to this type delete_volume_opts() View Source
delete_volume_opts() :: [{:dry_run, boolean()}]
Link to this type delete_vpc_opts() View Source
delete_vpc_opts() :: [{:dry_run, boolean()}]
Link to this type deregister_image_opts() View Source
deregister_image_opts() :: [{:dry_run, boolean()}]
Link to this type describe_account_attributes_opts() View Source
describe_account_attributes_opts() :: [
  attribute_names: [binary(), ...],
  dry_run: boolean()
]
Link to this type describe_availability_zones_opts() View Source
describe_availability_zones_opts() :: [
  dry_run: boolean(),
  zone_names: [binary(), ...],
  filters: [filter(), ...]
]
Link to this type describe_bundle_tasks_opts() View Source
describe_bundle_tasks_opts() :: [
  bundle_ids: [binary(), ...],
  dry_run: boolean(),
  filters: [filter(), ...]
]
Link to this type describe_id_format_opts() View Source
describe_id_format_opts() :: [{:resource, binary()}]
Link to this type describe_image_attribute_opts() View Source
describe_image_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type describe_images_opts() View Source
describe_images_opts() :: [
  dry_run: boolean(),
  executable_by_list: [binary(), ...],
  filters: [filter(), ...],
  image_ids: [binary(), ...],
  owners: [binary(), ...]
]
Link to this type describe_instance_attribute_opts() View Source
describe_instance_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type describe_instance_status_opts() View Source
describe_instance_status_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  include_all_instances: boolean(),
  instance_ids: [binary(), ...],
  max_results: integer(),
  next_token: binary()
]
Link to this type describe_instances_opts() View Source
describe_instances_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  include_all_instances: boolean(),
  instance_ids: [binary(), ...],
  max_results: integer(),
  next_token: binary()
]
Link to this type describe_key_pairs_opts() View Source
describe_key_pairs_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  key_names: [binary(), ...]
]
Link to this type describe_regions_opts() View Source
describe_regions_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  region_names: [binary(), ...]
]
Link to this type describe_security_groups_opts() View Source
describe_security_groups_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  group_ids: [binary(), ...],
  group_names: [binary(), ...]
]
Link to this type describe_snapshot_attribute_opts() View Source
describe_snapshot_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type describe_snapshots_opts() View Source
describe_snapshots_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  max_results: integer(),
  next_token: binary(),
  owners: [binary(), ...],
  restorable_by_ids: [binary(), ...],
  snapshot_ids: [binary(), ...]
]
Link to this type describe_subnets_opts() View Source
describe_subnets_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  subnet_ids: [binary(), ...]
]
Link to this type describe_tags_opts() View Source
describe_tags_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  max_results: integer(),
  next_token: binary()
]
Link to this type describe_volume_attribute_opts() View Source
describe_volume_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type describe_volume_status_opts() View Source
describe_volume_status_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  max_results: integer(),
  next_token: binary(),
  volume_ids: [binary(), ...]
]
Link to this type describe_volumes_opts() View Source
describe_volumes_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  max_results: integer(),
  next_token: binary(),
  volume_ids: [binary(), ...]
]
Link to this type describe_vpc_attribute_opts() View Source
describe_vpc_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type describe_vpcs_opts() View Source
describe_vpcs_opts() :: [
  dry_run: boolean(),
  filters: [filter(), ...],
  vpc_ids: [binary(), ...]
]
Link to this type detach_volume_opts() View Source
detach_volume_opts() :: [
  instance_id: binary(),
  force: boolean(),
  dry_run: boolean(),
  device: binary()
]
Link to this type ebs() View Source
ebs() :: [
  delete_on_termination: boolean(),
  encrypted: boolean(),
  iops: integer(),
  snapshot_id: binary(),
  volume_size: integer(),
  volume_type: binary()
]
Link to this type enable_volume_io_opts() View Source
enable_volume_io_opts() :: [{:dry_run, boolean()}]
Link to this type filter() View Source
filter() :: {name :: binary() | atom(), value :: [binary(), ...]}
Link to this type get_console_output_opts() View Source
get_console_output_opts() :: [{:dry_run, boolean()}]
Link to this type get_password_data_opts() View Source
get_password_data_opts() :: [{:dry_run, boolean()}]
Link to this type iam_instance_profile_spec() View Source
iam_instance_profile_spec() :: [arn: binary(), name: binary()]
Link to this type import_key_pair_opts() View Source
import_key_pair_opts() :: [{:dry_run, boolean()}]
Link to this type ip_permission() View Source
ip_permission() :: [
  from_port: integer(),
  user_id_group_pairs: [user_id_group_pair(), ...],
  ip_protocol: binary(),
  ip_ranges: [ip_range(), ...],
  ipv6_ranges: [ipv6_range(), ...],
  prefix_list_ids: [prefix_list_id(), ...],
  to_port: integer()
]
Link to this type ip_range() View Source
ip_range() :: [{:cidr_ip, binary()}]
Link to this type ipv6_address() View Source
ipv6_address() :: [{:ipv6_address, binary()}]
Link to this type ipv6_range() View Source
ipv6_range() :: [{:cidr_ipv6, binary()}]
Link to this type modify_image_attribute_opts() View Source
modify_image_attribute_opts() :: [
  attribute: binary(),
  description: attribute_value(),
  dry_run: boolean(),
  launch_permission: permission_modifications(),
  operation_type: binary(),
  product_codes: [binary(), ...],
  user_ids: [binary(), ...],
  user_groups: [binary(), ...],
  value: binary()
]
Link to this type modify_instance_attribute_opts() View Source
modify_instance_attribute_opts() :: [
  attribute: binary(),
  block_device_mappings: [block_device_mapping(), ...],
  disable_api_termination: attribute_boolean_value(),
  dry_run: boolean(),
  ebs_optimized: attribute_boolean_value(),
  ena_support: attribute_boolean_value(),
  group_ids: [binary(), ...],
  instance_initiated_shutdown_behavior: attribute_value(),
  instance_type: attribute_value(),
  kernel: attribute_value(),
  ramdisk: attribute_value(),
  source_dest_check: attribute_boolean_value(),
  sriov_net_support: binary(),
  user_data: attribute_value(),
  value: binary()
]
Link to this type modify_snapshot_attribute_opts() View Source
modify_snapshot_attribute_opts() :: [
  attribute: binary(),
  create_volume_permission: permission_modifications(),
  dry_run: boolean(),
  user_groups: [binary(), ...],
  user_ids: [binary(), ...]
]
Link to this type modify_subnet_attribute_opts() View Source
modify_subnet_attribute_opts() :: [
  map_public_ip_on_launch: boolean(),
  assign_ipv6_address_on_creation: boolean()
]
Link to this type modify_volume_attribute_opts() View Source
modify_volume_attribute_opts() :: [
  auto_enable_io: attribute_boolean_value(),
  dry_run: boolean()
]
Link to this type modify_volume_opts() View Source
modify_volume_opts() :: [
  dry_run: boolean(),
  iops: integer(),
  size: integer(),
  volume_type: binary()
]
Link to this type modify_vpc_attribute_opts() View Source
modify_vpc_attribute_opts() :: [
  enable_dns_hostnames: boolean(),
  enable_dns_support: boolean()
]
Link to this type monitor_instances_opts() View Source
monitor_instances_opts() :: [{:dry_run, boolean()}]
Link to this type monitoring_enabled() View Source
monitoring_enabled() :: [{:enabled, boolean()}]
Link to this type network_interface_spec() View Source
network_interface_spec() :: [
  associate_public_ip_address: boolean(),
  delete_on_termination: boolean(),
  description: binary(),
  device_index: integer(),
  ipv6_address_count: integer(),
  ipv6_addresses: [ipv6_address(), ...],
  network_interface_id: binary(),
  private_ip_address: binary(),
  private_ip_addresses: [private_ip_address_spec(), ...],
  secondary_ip_address_count: integer(),
  groups: [binary(), ...],
  subnet_id: binary()
]
Link to this type permission() View Source
permission() :: [group: binary(), user_id: binary()]
Link to this type permission_modifications() View Source
permission_modifications() :: [
  add: [permission(), ...],
  remove: [permission(), ...]
]
Link to this type placement() View Source
placement() :: [
  affinity: binary(),
  availability_zone: binary(),
  group_name: binary(),
  host_id: binary(),
  spread_domain: binary(),
  tenancy: binary()
]
Link to this type prefix_list_id() View Source
prefix_list_id() :: [{:prefix_list_id, binary()}]
Link to this type private_ip_address_spec() View Source
private_ip_address_spec() :: [primary: boolean(), private_ip_address: binary()]
Link to this type reboot_instances_opts() View Source
reboot_instances_opts() :: [{:dry_run, boolean()}]
Link to this type register_image_opts() View Source
register_image_opts() :: [
  architecture: binary(),
  billing_products: [binary(), ...],
  block_device_mappings: [block_device_mapping(), ...],
  description: binary(),
  dry_run: boolean(),
  ena_support: boolean(),
  image_location: binary(),
  kernel_id: binary(),
  ramdisk_id: binary(),
  root_device_name: binary(),
  sriov_net_support: binary(),
  virtualization_type: binary()
]
Link to this type report_instance_status_opts() View Source
report_instance_status_opts() :: [
  description: binary(),
  dry_run: boolean(),
  end_time: %DateTime{
    calendar: term(),
    day: term(),
    hour: term(),
    microsecond: term(),
    minute: term(),
    month: term(),
    second: term(),
    std_offset: term(),
    time_zone: term(),
    utc_offset: term(),
    year: term(),
    zone_abbr: term()
  },
  reason_codes: [binary(), ...],
  start_time: %DateTime{
    calendar: term(),
    day: term(),
    hour: term(),
    microsecond: term(),
    minute: term(),
    month: term(),
    second: term(),
    std_offset: term(),
    time_zone: term(),
    utc_offset: term(),
    year: term(),
    zone_abbr: term()
  }
]
Link to this type reset_image_attribute_opts() View Source
reset_image_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type reset_instance_attribute_opts() View Source
reset_instance_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type reset_snapshot_attribute_opts() View Source
reset_snapshot_attribute_opts() :: [{:dry_run, boolean()}]
Link to this type revoke_security_group_egress_opts() View Source
revoke_security_group_egress_opts() :: [
  cidr_ip: binary(),
  dry_run: boolean(),
  from_port: integer(),
  ip_permissions: [ip_permission(), ...],
  ip_protocol: binary(),
  source_security_group_name: binary(),
  source_security_group_owner_id: binary(),
  to_port: integer()
]
Link to this type revoke_security_group_ingress_opts() View Source
revoke_security_group_ingress_opts() :: [
  cidr_ip: binary(),
  dry_run: boolean(),
  from_port: integer(),
  group_id: binary(),
  group_name: binary(),
  ip_permissions: [ip_permission(), ...],
  ip_protocol: binary(),
  source_security_group_name: binary(),
  source_security_group_owner_id: binary(),
  to_port: integer()
]
Link to this type run_instances_opts() View Source
run_instances_opts() :: [
  additional_info: binary(),
  block_device_mappings: [block_device_mapping(), ...],
  client_token: binary(),
  disable_api_termination: boolean(),
  dry_run: boolean(),
  ebs_optimized: boolean(),
  iam_instance_profile: iam_instance_profile_spec(),
  image_id: binary(),
  instance_initiated_shutdown_behavior: binary(),
  instance_type: binary(),
  ipv6_addresses: [ipv6_address(), ...],
  ipv6_address_count: integer(),
  kernel_id: binary(),
  key_name: binary(),
  max_count: integer(),
  min_count: integer(),
  monitoring: monitoring_enabled(),
  network_interfaces: [network_interface_spec(), ...],
  placement: placement(),
  private_ip_address: binary(),
  ramdisk_id: binary(),
  security_groups: [binary(), ...],
  security_group_ids: [binary(), ...],
  subnet_id: binary(),
  tag_specifications: [tag_specification(), ...],
  user_data: binary()
]
Link to this type start_instances_opts() View Source
start_instances_opts() :: [additional_info: binary(), dry_run: boolean()]
Link to this type stop_instances_opts() View Source
stop_instances_opts() :: [dry_run: boolean(), force: boolean()]
Link to this type tag() View Source
tag() :: {key :: atom(), value :: binary()}
Link to this type tag_specification() View Source
tag_specification() :: {resource_type :: binary(), tags :: [tag(), ...]}
Link to this type terminate_instances_opts() View Source
terminate_instances_opts() :: [{:dry_run, boolean()}]
Link to this type unmonitor_instances_opts() View Source
unmonitor_instances_opts() :: [{:dry_run, boolean()}]
Link to this type user_id_group_pair() View Source
user_id_group_pair() :: [
  group_id: binary(),
  group_name: binary(),
  peering_status: binary(),
  user_id: binary(),
  vpc_id: binary(),
  vpc_peering_connection_id: binary()
]

Link to this section Functions

Link to this function attach_volume(instance_id, volume_id, device, opts \\ []) View Source
attach_volume(
  instance_id :: binary(),
  volume_id :: binary(),
  device :: binary(),
  opts :: attach_volume_opts()
) :: ExAws.Operation.Query.t()

Attaches a volume to a specified instance

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_AttachVolume.html

Examples:

iex> ExAws.EC2.attach_volume("i-123456", "vol-123456", "/dev/sdh")
%ExAws.Operation.Query{action: :attach_volume,
params: %{
  "Action" => "AttachVolume",
  "InstanceId" => "i-123456",
  "VolumeId" => "vol-123456",
  "Device" => "/dev/sdh",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function authorize_security_group_egress(group_id, opts \\ []) View Source
authorize_security_group_egress(
  group_id :: binary(),
  opts :: authorize_security_group_egress_opts()
) :: ExAws.Operation.Query.t()

Adds one or more egress rules to a security group for use with a VPC.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_AuthorizeSecurityGroupEgress.html

Examples:

iex> ExAws.EC2.authorize_security_group_egress("sg-1a2b3c4d", [group_name: "websrv",
  ...> ip_permissions: [
  ...>  [ip_protocol: "tcp", from_port: 1433, to_port: 1433, user_id_group_pairs: [
  ...>    [group_id: "sg-9a8d7f5c", group_name: "test"],
  ...>    [group_name: "blah"]
  ...>  ]],
  ...>  [ip_protocol: "udp", from_port: 1234]
  ...> ]])
  %ExAws.Operation.Query{action: :authorize_security_group_egress,
  params: %{
    "Action" => "AuthorizeSecurityGroupEgress",
    "GroupId" => "sg-1a2b3c4d",
    "GroupName" => "websrv",
    "IpPermissions.1.IpProtocol" => "tcp",
    "IpPermissions.1.FromPort" => 1433,
    "IpPermissions.1.ToPort" => 1433,
    "IpPermissions.1.UserIdGroupPairs.1.GroupId" => "sg-9a8d7f5c",
    "IpPermissions.1.UserIdGroupPairs.1.GroupName" => "test",
    "IpPermissions.1.UserIdGroupPairs.2.GroupName" => "blah",
    "IpPermissions.2.IpProtocol" => "udp",
    "IpPermissions.2.FromPort" => 1234,
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function authorize_security_group_ingress(opts \\ []) View Source
authorize_security_group_ingress(
  opts :: authorize_security_group_ingress_opts()
) :: ExAws.Operation.Query.t()

Adds one or more ingress rules to a security group.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_AuthorizeSecurityGroupIngress.html

Examples:

iex> ExAws.EC2.authorize_security_group_ingress([group_id: "sg-1a2b3c4d",
  ...>  ip_permissions: [
  ...>    [ip_protocol: "tcp", from_port: 22, to_port: 22, ipv6_ranges: [
  ...>      [cidr_ipv6: "2001:db8:1234:1a00::/64"]
  ...>    ]]
  ...>  ]
  ...> ])
  %ExAws.Operation.Query{action: :authorize_security_group_ingress,
  params: %{
    "Action" => "AuthorizeSecurityGroupIngress",
    "GroupId" => "sg-1a2b3c4d",
    "IpPermissions.1.IpProtocol" => "tcp",
    "IpPermissions.1.FromPort" => 22,
    "IpPermissions.1.ToPort" => 22,
    "IpPermissions.1.Ipv6Ranges.1.CidrIpv6" => "2001:db8:1234:1a00::/64",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function bundle_instance(instance_id, s3_aws_access_key_id, s3_bucket, s3_prefix, s3_upload_policy, s3_upload_policy_signature, opts \\ []) View Source
bundle_instance(
  instance_id :: binary(),
  s3_aws_access_key_id :: binary(),
  s3_bucket :: binary(),
  s3_prefix :: binary(),
  s3_upload_policy :: binary(),
  s3_upload_policy_signature :: binary(),
  opts :: bundle_instance_opts()
) :: ExAws.Operation.Query.t()

Bundles an Amazon instance store-backed Windows instance. During bundling, only the root device volume (C:) is bundled. Data on other instance store volumes is not preserved.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_BundleInstance.html

Examples:

iex> ExAws.EC2.bundle_instance("i-123456", "TestS3AccessKeyId", "TestS3Bucket", "TestS3Prefix", "TestS3UploadPolicy", "TestS3UploadPolicySig")
%ExAws.Operation.Query{action: :bundle_instance,
params: %{
  "Action" => "BundleInstance",
  "InstanceId" => "i-123456",
  "Storage.S3.AWSAccessKeyId" => "TestS3AccessKeyId",
  "Storage.S3.Bucket" => "TestS3Bucket",
  "Storage.S3.Prefix" => "TestS3Prefix",
  "Storage.S3.UploadPolicy" => "TestS3UploadPolicy",
  "Storage.S3.UploadPolicySignature" => "TestS3UploadPolicySig",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function cancel_bundle_task(bundle_id, opts \\ []) View Source
cancel_bundle_task(bundle_id :: binary(), opts :: cancel_bundle_task_opts()) ::
  ExAws.Operation.Query.t()

Cancels a bundling operation for an instance store-backed Windows instance.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CancelBundleTask.html

Examples:

iex> ExAws.EC2.cancel_bundle_task("TestBundleId")
  %ExAws.Operation.Query{action: :cancel_bundle_task,
  params: %{
    "Action" => "CancelBundleTask",
    "BundleId" => "TestBundleId",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.cancel_bundle_task("bun-c1a540a8", [dry_run: true])
  %ExAws.Operation.Query{action: :cancel_bundle_task,
  params: %{
    "Action" => "CancelBundleTask",
    "BundleId" => "bun-c1a540a8",
    "DryRun" => true,
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function copy_image(name, source_image_id, source_region, opts \\ []) View Source
copy_image(
  name :: binary(),
  source_image_id :: binary(),
  source_region :: binary(),
  opts :: copy_image_opts()
) :: ExAws.Operation.Query.t()

Initiates the copy of an AMI from the specified source region to the current region. You specify the destination region by using its endpoint when making the request.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CopyImage.html

Examples:

iex> ExAws.EC2.copy_image("Test", "ami-123456", "us-east-1")
%ExAws.Operation.Query{action: :copy_image,
params: %{
  "Action" => "CopyImage",
  "Name" => "Test",
  "SourceImageId" => "ami-123456",
  "SourceRegion" => "us-east-1",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function copy_snapshot(source_snapshot_id, source_region, opts \\ []) View Source
copy_snapshot(
  source_snapshot_id :: binary(),
  source_region :: binary(),
  opts :: copy_snapshot_opts()
) :: ExAws.Operation.Query.t()

Copies a point-in-time snapshot of an EBS volume and stores it in Amazon S3. You can copy the snapshot within the same region or from one region to another.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CopySnapshot.html

Examples:

iex> ExAws.EC2.copy_snapshot("snap-123456", "us-east-1a")
  %ExAws.Operation.Query{action: :copy_snapshot,
  params: %{
    "Action" => "CopySnapshot",
    "SourceSnapshotId" => "snap-123456",
    "SourceRegion" => "us-east-1a",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.copy_snapshot("snap-123456", "us-east-1a", [description: "TestDescription", encrypted: true, kms_key_id: "TestKmsKeyId"])
  %ExAws.Operation.Query{action: :copy_snapshot,
  params: %{
    "Action" => "CopySnapshot",
    "SourceSnapshotId" => "snap-123456",
    "SourceRegion" => "us-east-1a",
    "Description" => "TestDescription",
    "Encrypted" => true,
    "KmsKeyId" => "TestKmsKeyId",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_image(instance_id, name, opts \\ []) View Source
create_image(
  instance_id :: binary(),
  name :: binary(),
  opts :: create_image_opts()
) :: ExAws.Operation.Query.t()

Creates an Amazon EBS-backed AMI from an Amazon EBS-backed instance that is either running or stopped.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateImage.html

Examples:

iex> ExAws.EC2.create_image("i-123456", "Test")
%ExAws.Operation.Query{action: :create_image,
params: %{
  "Action" => "CreateImage",
  "InstanceId" => "i-123456",
  "Name" => "Test",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_key_pair(key_name, opts \\ []) View Source
create_key_pair(key_name :: binary(), opts :: create_key_pair_opts()) ::
  ExAws.Operation.Query.t()

Creates a 2048-bit RSA key pair with the specified name. Amazon EC2 stores the public key and displays the private key for you to save to a file. The private key is returned as an unencrypted PEM encoded PKCS#8 private key.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html

Examples:

iex> ExAws.EC2.create_key_pair("my-key-pair", [dry_run: true])
%ExAws.Operation.Query{action: :create_key_pair,
params: %{
  "Action" => "CreateKeyPair",
  "KeyName" => "my-key-pair",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_security_group(group_name, group_description, opts \\ []) View Source
create_security_group(
  group_name :: binary(),
  group_description :: binary(),
  opts :: create_security_group_opts()
) :: ExAws.Operation.Query.t()

Creates a security group.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateSecurityGroup.html

Examples:

iex> ExAws.EC2.create_security_group("websrv", "Web Servers")
%ExAws.Operation.Query{action: :create_security_group,
params: %{
  "Action" => "CreateSecurityGroup",
  "GroupName" => "websrv",
  "GroupDescription" => "Web Servers",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_snapshot(volume_id, opts \\ []) View Source
create_snapshot(volume_id :: binary(), opts :: create_snapshot_opts()) ::
  ExAws.Operation.Query.t()

Creates a snapshot of an EBS volume and stores it in Amazon S3. You can use snapshots for backups, to make copies of EBS volumes, and to save data before shutting down an instance.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateSnapshot.html

Examples:

iex> ExAws.EC2.create_snapshot("vol-123456")
  %ExAws.Operation.Query{action: :create_snapshot,
  params: %{
    "Action" => "CreateSnapshot",
    "VolumeId" => "vol-123456",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.create_snapshot("vol-123456", [description: "Test Description"])
  %ExAws.Operation.Query{action: :create_snapshot,
  params: %{
    "Action" => "CreateSnapshot",
    "VolumeId" => "vol-123456",
    "Description" => "Test Description",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_subnet(vpc_id, cidr_block, opts \\ []) View Source
create_subnet(
  vpc_id :: binary(),
  cidr_block :: binary(),
  opts :: create_subnet_opts()
) :: ExAws.Operation.Query.t()

Creates a subnet in an existing VPC.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateSubnet.html

Examples:

iex> ExAws.EC2.create_subnet("vpc-1a2b3c4d", "10.0.1.0/24", [ipv6_cidr_block: "2001:db8:1234:1a00::/64"])
  %ExAws.Operation.Query{action: :create_subnet,
  params: %{
    "Action" => "CreateSubnet",
    "VpcId" => "vpc-1a2b3c4d",
    "CidrBlock" => "10.0.1.0/24",
    "Ipv6CidrBlock" => "2001:db8:1234:1a00::/64",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_tags(resource_ids, tags, opts \\ []) View Source
create_tags(
  resource_ids :: [binary(), ...],
  tags :: [tag(), ...],
  opts :: create_tags_opts()
) :: ExAws.Operation.Query.t()

Adds or overwrites one or more tags for the specified Amazon EC2 resource or resources. Each resource can have a maximum of 10 tags. Each tag consists of a key and optional value. Tag keys must be unique per resource.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html

Examples:

iex> ExAws.EC2.create_tags(["i-123456", "snap-123456"], ["automation": "test", "owner": "TestOwner"])
%ExAws.Operation.Query{action: :create_tags,
params: %{
  "Action" => "CreateTags",
  "ResourceId.1" => "i-123456",
  "ResourceId.2" => "snap-123456",
  "Tag.1.Key" => "automation",
  "Tag.1.Value" => "test",
  "Tag.2.Key" => "owner",
  "Tag.2.Value" => "TestOwner",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_volume(availability_zone, opts \\ []) View Source
create_volume(availability_zone :: binary(), opts :: create_volume_opts()) ::
  ExAws.Operation.Query.t()

Creates an EBS volume that can be attached to an instance in the same Availability Zone

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateVolume.html

Examples:

iex> ExAws.EC2.create_volume("us-east-1")
%ExAws.Operation.Query{action: :create_volume,
params: %{
  "Action" => "CreateVolume",
  "AvailabilityZone" => "us-east-1",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function create_vpc(cidr_block, opts \\ []) View Source
create_vpc(cidr_block :: binary(), opts :: create_vpc_opts()) ::
  ExAws.Operation.Query.t()

Creates a VPC with the specified CIDR block.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateVpc.html

Examples:

iex> ExAws.EC2.create_vpc("10.32.0.0/16", [instance_tenancy: "dedicated"])
  %ExAws.Operation.Query{action: :create_vpc,
  params: %{
    "Action" => "CreateVpc",
    "CidrBlock" => "10.32.0.0/16",
    "InstanceTenancy" => "dedicated",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_key_pair(key_name, opts \\ []) View Source
delete_key_pair(key_name :: binary(), opts :: delete_key_pair_opts()) ::
  ExAws.Operation.Query.t()

Deletes the specified key pair, by removing the public key from Amazon EC2.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteKeyPair.html

Examples:

iex> ExAws.EC2.create_key_pair("my-key-pair", [dry_run: true])
%ExAws.Operation.Query{action: :create_key_pair,
params: %{
  "Action" => "CreateKeyPair",
  "KeyName" => "my-key-pair",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_snapshot(snapshot_id, opts \\ []) View Source
delete_snapshot(snapshot_id :: binary(), opts :: delete_snapshot_opts()) ::
  ExAws.Operation.Query.t()

Deletes the specified snapshot.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteSnapshot.html

Examples:

iex> ExAws.EC2.delete_snapshot("snap-123456")
%ExAws.Operation.Query{action: :delete_snapshot,
params: %{
  "Action" => "DeleteSnapshot",
  "SnapshotId" => "snap-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.delete_snapshot("snap-123456", [dry_run: true])
%ExAws.Operation.Query{action: :delete_snapshot,
params: %{
  "Action" => "DeleteSnapshot",
  "SnapshotId" => "snap-123456",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_subnet(subnet_id, opts \\ []) View Source
delete_subnet(subnet_id :: binary(), opts :: delete_subnet_opts()) ::
  ExAws.Operation.Query.t()

Deletes the specified subnet.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteSubnet.html

Examples:

iex> ExAws.EC2.delete_subnet("subnet-9d4a7b6c", [dry_run: true])
%ExAws.Operation.Query{action: :delete_subnet,
params: %{
  "Action" => "DeleteSubnet",
  "SubnetId" => "subnet-9d4a7b6c",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_tags(resource_ids, opts \\ []) View Source
delete_tags(resource_ids :: [binary(), ...], opts :: delete_tags_opts()) ::
  ExAws.Operation.Query.t()

Deletes the specified set of tags from the specified set of resources.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteTags.html

Examples:

iex> ExAws.EC2.delete_tags(["i-123456", "snap-123456"])
%ExAws.Operation.Query{action: :delete_tags,
params: %{
  "Action" => "DeleteTags",
  "ResourceId.1" => "i-123456",
  "ResourceId.2" => "snap-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.delete_tags(["i-123456", "snap-123456"], [tags: ["name": "Test", "owner": "TestOwner"]])
%ExAws.Operation.Query{action: :delete_tags,
params: %{
  "Action" => "DeleteTags",
  "ResourceId.1" => "i-123456",
  "ResourceId.2" => "snap-123456",
  "Tag.1.Key" => "name",
  "Tag.1.Value" => "Test",
  "Tag.2.Key" => "owner",
  "Tag.2.Value" => "TestOwner",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_volume(volume_id, opts \\ []) View Source
delete_volume(volume_id :: binary(), opts :: delete_volume_opts()) ::
  ExAws.Operation.Query.t()

Deletes a specified volume

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteVolume.html

Examples:

iex> ExAws.EC2.delete_volume("vol-123456")
%ExAws.Operation.Query{action: :delete_volume,
params: %{
  "Action" => "DeleteVolume",
  "VolumeId" => "vol-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function delete_vpc(vpc_id, opts \\ []) View Source
delete_vpc(vpc_id :: binary(), opts :: delete_vpc_opts()) ::
  ExAws.Operation.Query.t()

Deletes the specified VPC.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeleteVpc.html

Examples:

iex> ExAws.EC2.delete_vpc("vpc-123456", [dry_run: true])
%ExAws.Operation.Query{action: :delete_vpc,
params: %{
  "Action" => "DeleteVpc",
  "VpcId" => "vpc-123456",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function deregister_image(image_id, opts \\ []) View Source
deregister_image(image_id :: binary(), opts :: deregister_image_opts()) ::
  ExAws.Operation.Query.t()

Deregisters the specified AMI. After you deregister an AMI, it can’t be used to launch new instances.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DeregisterImage.html

Examples:

iex> ExAws.EC2.deregister_image("ami-123456")
%ExAws.Operation.Query{action: :deregister_image,
params: %{
  "Action" => "DeregisterImage",
  "ImageId" => "ami-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_account_attributes(opts \\ []) View Source
describe_account_attributes(opts :: describe_account_attributes_opts()) ::
  ExAws.Operation.Query.t()

Describes attributes of your AWS account.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeAccountAttributes.html

Examples:

iex> ExAws.EC2.describe_account_attributes
%ExAws.Operation.Query{action: :describe_account_attributes,
params: %{
  "Action" => "DescribeAccountAttributes",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_account_attributes([attribute_names: ["supported-platforms", "default-vpc"], dry_run: true])
%ExAws.Operation.Query{action: :describe_account_attributes,
params: %{
  "Action" => "DescribeAccountAttributes",
  "AttributeName.1" => "supported-platforms",
  "AttributeName.2" => "default-vpc",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_availability_zones(opts \\ []) View Source
describe_availability_zones(opts :: describe_availability_zones_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more of the Availability Zones that are available to you. The results include zones only for the region you’re currently using.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeAvailabilityZones.html

Examples:

iex> ExAws.EC2.describe_availability_zones
  %ExAws.Operation.Query{action: :describe_availability_zones,
  params: %{
    "Action" => "DescribeAvailabilityZones",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_bundle_tasks(opts \\ []) View Source
describe_bundle_tasks(opts :: describe_bundle_tasks_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more of your bundling tasks.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeBundleTasks.html

Examples:

iex> ExAws.EC2.describe_bundle_tasks
  %ExAws.Operation.Query{action: :describe_bundle_tasks,
  params: %{
    "Action" => "DescribeBundleTasks",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_bundle_tasks([bundle_ids: ["bun-123456", "bun-1a2b3c"]])
  %ExAws.Operation.Query{action: :describe_bundle_tasks,
  params: %{
    "Action" => "DescribeBundleTasks",
    "BundleId.1" => "bun-123456",
    "BundleId.2" => "bun-1a2b3c",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_id_format(opts \\ []) View Source
describe_id_format(opts :: describe_id_format_opts()) ::
  ExAws.Operation.Query.t()

Describes the ID format settings for your resources on a per-region basis, for example, to view which resource types are enabled for longer IDs.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeIdFormat.html

Examples:

iex> ExAws.EC2.describe_id_format
%ExAws.Operation.Query{action: :describe_id_format,
params: %{
  "Action" => "DescribeIdFormat",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_id_format([resource: "instance"])
%ExAws.Operation.Query{action: :describe_id_format,
params: %{
  "Action" => "DescribeIdFormat",
  "Resource" => "instance",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_image_attribute(image_id, attribute, opts \\ []) View Source
describe_image_attribute(
  image_id :: binary(),
  attribute :: binary(),
  opts :: describe_image_attribute_opts()
) :: ExAws.Operation.Query.t()

Describes the specified attribute of the specified AMI. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeImageAttribute.html

Examples:

iex> ExAws.EC2.describe_image_attribute("ami-123456", "description")
%ExAws.Operation.Query{action: :describe_image_attribute,
params: %{
  "Action" => "DescribeImageAttribute",
  "ImageId" => "ami-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_images(opts \\ []) View Source
describe_images(opts :: describe_images_opts()) :: ExAws.Operation.Query.t()

Describes one or more of the images (AMIs, AKIs, and ARIs) available to you.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeImages.html

Examples:

iex> ExAws.EC2.describe_images
%ExAws.Operation.Query{action: :describe_images,
params: %{
  "Action" => "DescribeImages",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_images([image_ids: ["ami-123456", "ami-1a2b3c4d"]])
%ExAws.Operation.Query{action: :describe_images,
params: %{
  "Action" => "DescribeImages",
  "ImageId.1" => "ami-123456",
  "ImageId.2" => "ami-1a2b3c4d",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_instance_attribute(instance_id, attribute, opts \\ []) View Source
describe_instance_attribute(
  instance_id :: binary(),
  attribute :: binary(),
  opts :: describe_instance_attribute_opts()
) :: ExAws.Operation.Query.t()

Describes the specified attribute of the specified instance. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeInstanceAttribute.html

Examples:

iex> ExAws.EC2.describe_instance_attribute("i-123456", "description")
%ExAws.Operation.Query{action: :describe_instance_attribute,
params: %{
  "Action" => "DescribeInstanceAttribute",
  "InstanceId" => "i-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_instance_status(opts \\ []) View Source
describe_instance_status(opts :: describe_instance_status_opts()) ::
  ExAws.Operation.Query.t()

Describes the status of one or more instances. By default, only running instances are described, unless specified otherwise.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeInstanceStatus.html

Examples:

iex> ExAws.EC2.describe_instance_status
%ExAws.Operation.Query{action: :describe_instance_status,
params: %{
  "Action" => "DescribeInstanceStatus",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_instance_status([instance_ids: ["i-123456", "i-1a2b3c"]])
%ExAws.Operation.Query{action: :describe_instance_status,
params: %{
  "Action" => "DescribeInstanceStatus",
  "InstanceId.1" => "i-123456",
  "InstanceId.2" => "i-1a2b3c",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_instances(opts \\ []) View Source
describe_instances(opts :: describe_instances_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more instances. If you specify the instance IDs or filters, Amazon EC2 returns information for those instances. If you do not specify an instance ID or filters, then it’ll all the relevant instances

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeInstances.html

Examples:

iex> ExAws.EC2.describe_instances
%ExAws.Operation.Query{action: :describe_instances,
params: %{
  "Action" => "DescribeInstances",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_instances([filters: ["instance-type": ["m1.small", "m3.medium"]]])
%ExAws.Operation.Query{action: :describe_instances,
params: %{
  "Action" => "DescribeInstances",
  "Filter.1.Name" => "instance-type",
  "Filter.1.Value.1" => "m1.small",
  "Filter.1.Value.2" => "m3.medium",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_key_pairs(opts \\ []) View Source
describe_key_pairs(opts :: describe_key_pairs_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more of your key pairs.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeKeyPairs.html

Examples:

iex> ExAws.EC2.describe_key_pairs
%ExAws.Operation.Query{action: :describe_key_pairs,
params: %{
  "Action" => "DescribeKeyPairs",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_key_pairs([key_names: ["my-key-pair", "test-key-pair"]])
%ExAws.Operation.Query{action: :describe_key_pairs,
params: %{
  "Action" => "DescribeKeyPairs",
  "KeyName.1" => "my-key-pair",
  "KeyName.2" => "test-key-pair",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_regions(opts \\ []) View Source
describe_regions(opts :: describe_regions_opts()) :: ExAws.Operation.Query.t()

Describes one or more regions that are currently available to you.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeRegions.html

Examples:

iex> ExAws.EC2.describe_regions
  %ExAws.Operation.Query{action: :describe_regions,
  params: %{
    "Action" => "DescribeRegions",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_regions([region_names: ["us-east-1", "eu-west-1"]])
  %ExAws.Operation.Query{action: :describe_regions,
  params: %{
    "Action" => "DescribeRegions",
    "RegionName.1" => "us-east-1",
    "RegionName.2" => "eu-west-1",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_security_groups(opts \\ []) View Source
describe_security_groups(opts :: describe_security_groups_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more of your security groups.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html

Examples:

iex> ExAws.EC2.describe_security_groups
  %ExAws.Operation.Query{action: :describe_security_groups,
  params: %{
    "Action" => "DescribeSecurityGroups",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_security_groups([filters: ["ip.permission.protocol": ["tcp"], "ip-permission.group_name": ["app_server_group", "database_group"]]])
  %ExAws.Operation.Query{action: :describe_security_groups,
  params: %{
    "Action" => "DescribeSecurityGroups",
    "Filter.1.Name" => "ip.permission.protocol",
    "Filter.1.Value.1" => "tcp",
    "Filter.2.Name" => "ip-permission.group_name",
    "Filter.2.Value.1" => "app_server_group",
    "Filter.2.Value.2" => "database_group",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_snapshot_attribute(snapshot_id, attribute, opts \\ []) View Source
describe_snapshot_attribute(
  snapshot_id :: binary(),
  attribute :: binary(),
  opts :: describe_snapshot_attribute_opts()
) :: ExAws.Operation.Query.t()

Describes the specified attribute of the specified snapshot. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSnapshotAttribute.html

Examples:

iex> ExAws.EC2.describe_snapshot_attribute("snap-123456", "description")
%ExAws.Operation.Query{action: :describe_snapshot_attribute,
params: %{
  "Action" => "DescribeSnapshotAttribute",
  "SnapshotId" => "snap-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_snapshots(opts \\ []) View Source
describe_snapshots(opts :: describe_snapshots_opts()) ::
  ExAws.Operation.Query.t()

Describes one or more of the EBS snapshots available to you.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSnapshots.html

Examples:

iex> ExAws.EC2.describe_snapshots
  %ExAws.Operation.Query{action: :describe_snapshots,
  params: %{
    "Action" => "DescribeSnapshots",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_snapshots([snapshot_ids: ["snap-123456", "snap-1a2b3c", "snap-987654"]])
  %ExAws.Operation.Query{action: :describe_snapshots,
  params: %{
    "Action" => "DescribeSnapshots",
    "SnapshotId.1" => "snap-123456",
    "SnapshotId.2" => "snap-1a2b3c",
    "SnapshotId.3" => "snap-987654",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_subnets(opts \\ []) View Source
describe_subnets(opts :: describe_subnets_opts()) :: ExAws.Operation.Query.t()

Describes one or more of your subnets.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSubnets.html

Examples:

iex> ExAws.EC2.describe_subnets([subnet_ids: ["subnet-9d4a7b6c", "subnet-6e7f829e"]])
  %ExAws.Operation.Query{action: :describe_subnets,
  params: %{
    "Action" => "DescribeSubnets",
    "SubnetId.1" => "subnet-9d4a7b6c",
    "SubnetId.2" => "subnet-6e7f829e",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_subnets(filters: ["vpc-id": ["vpc-1a2b3c4d", "vpc-6e7f8a92"], "state": ["available"]])
  %ExAws.Operation.Query{action: :describe_subnets,
  params: %{
    "Action" => "DescribeSubnets",
    "Filter.1.Name" => "vpc-id",
    "Filter.1.Value.1" => "vpc-1a2b3c4d",
    "Filter.1.Value.2" => "vpc-6e7f8a92",
    "Filter.2.Name" => "state",
    "Filter.2.Value.1" => "available",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_tags(opts \\ []) View Source
describe_tags(opts :: describe_tags_opts()) :: ExAws.Operation.Query.t()

Describes one or more of the tags for your EC2 resources.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeTags.html NOTE: If you need to pass in filters, pay special attention to what is allowed to be passed in in the doc.

Examples:

iex> ExAws.EC2.describe_tags
  %ExAws.Operation.Query{action: :describe_tags,
  params: %{
    "Action" => "DescribeTags",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_tags([filters: ["resource-type": ["instance", "snapshot"]]])
  %ExAws.Operation.Query{action: :describe_tags,
  params: %{
    "Action" => "DescribeTags",
    "Filter.1.Name" => "resource-type",
    "Filter.1.Value.1" => "instance",
    "Filter.1.Value.2" => "snapshot",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_volume_attribute(volume_id, attribute, opts \\ []) View Source
describe_volume_attribute(
  volume_id :: binary(),
  attribute :: binary(),
  opts :: describe_volume_attribute_opts()
) :: ExAws.Operation.Query.t()

Describes the specified attribute of the specified volume. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVolumeAttribute.html

Examples:

iex> ExAws.EC2.describe_volume_attribute("vol-123456", "description")
  %ExAws.Operation.Query{action: :describe_volume_attribute,
  params: %{
    "Action" => "DescribeVolumeAttribute",
    "VolumeId" => "vol-123456",
    "Attribute" => "description",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_volume_status(opts \\ []) View Source
describe_volume_status(opts :: describe_volume_status_opts()) ::
  ExAws.Operation.Query.t()

Describes the status of the specified volumes.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVolumeStatus.html

Examples:

iex> ExAws.EC2.describe_volume_status
  %ExAws.Operation.Query{action: :describe_volume_status,
  params: %{
    "Action" => "DescribeVolumeStatus",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_volume_status(
  ...> [
  ...>  filters: [
  ...>    "availability-zone": ["us-east-1d"],
  ...>    "volume-status.details-name": ["io-enabled", "test"],
  ...>    "status.details-status": ["failed"]
  ...>  ]
  ...> ])
  %ExAws.Operation.Query{action: :describe_volume_status,
  params: %{
    "Action" => "DescribeVolumeStatus",
    "Filter.1.Name" => "availability-zone",
    "Filter.1.Value.1" => "us-east-1d",
    "Filter.2.Name" => "volume-status.details-name",
    "Filter.2.Value.1" => "io-enabled",
    "Filter.2.Value.2" => "test",
    "Filter.3.Name" => "status.details-status",
    "Filter.3.Value.1" => "failed",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_volumes(opts \\ []) View Source
describe_volumes(opts :: describe_volumes_opts()) :: ExAws.Operation.Query.t()

Describes the specified EBS volumes.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVolumes.html

Examples:

iex> ExAws.EC2.describe_volumes
  %ExAws.Operation.Query{action: :describe_volumes,
  params: %{
    "Action" => "DescribeVolumes",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.describe_volumes([max_results: 10, next_token: "TestToken",
  ...>  volume_ids: ["vol-123456", "vol-987654"]
  ...> ])
  %ExAws.Operation.Query{action: :describe_volumes,
  params: %{
    "Action" => "DescribeVolumes",
    "MaxResults" => 10,
    "NextToken" => "TestToken",
    "VolumeId.1" => "vol-123456",
    "VolumeId.2" => "vol-987654",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_vpc_attribute(vpc_id, attribute, opts \\ []) View Source
describe_vpc_attribute(
  vpc_id :: binary(),
  attribute :: binary(),
  opts :: describe_vpc_attribute_opts()
) :: ExAws.Operation.Query.t()

Describes the specified attribute of the specified VPC. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpcAttribute.html

Examples:

iex> ExAws.EC2.describe_vpc_attribute("vpc-123456", "enableDnsSupport", [dry_run: true])
%ExAws.Operation.Query{action: :describe_vpc_attribute,
params: %{
  "Action" => "DescribeVpcAttribute",
  "Attribute" => "enableDnsSupport",
  "VpcId" => "vpc-123456",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function describe_vpcs(opts \\ []) View Source
describe_vpcs(opts :: describe_vpcs_opts()) :: ExAws.Operation.Query.t()

Describes one or more of your VPCs.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpcs.html

Examples:

iex> ExAws.EC2.describe_vpcs
%ExAws.Operation.Query{action: :describe_vpcs,
params: %{
  "Action" => "DescribeVpcs",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.describe_vpcs(vpc_ids: ["vpc-1a2b3c4d", "vpc-5e6f7g8h"])
%ExAws.Operation.Query{action: :describe_vpcs,
params: %{
  "Action" => "DescribeVpcs",
  "VpcId.1" => "vpc-1a2b3c4d",
  "VpcId.2" => "vpc-5e6f7g8h",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function detach_volume(volume_id, opts \\ []) View Source
detach_volume(volume_id :: binary(), opts :: detach_volume_opts()) ::
  ExAws.Operation.Query.t()

Detaches a specific volume

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DetachVolume.html

Examples:

iex> ExAws.EC2.detach_volume("vol-123456")
%ExAws.Operation.Query{action: :detach_volume,
params: %{
  "Action" => "DetachVolume",
  "VolumeId" => "vol-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function enable_volume_io(volume_id, opts \\ []) View Source
enable_volume_io(volume_id :: binary(), opts :: enable_volume_io_opts()) ::
  ExAws.Operation.Query.t()

Enables I/O operations for a volume that had I/O operations disabled because the data on the volume was potentially inconsistent.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_EnableVolumeIO.html

Examples:

iex> ExAws.EC2.enable_volume_io("vol-123456")
  %ExAws.Operation.Query{action: :enable_volume_i_o,
  params: %{
    "Action" => "EnableVolumeIO",
    "VolumeId" => "vol-123456",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function get_console_output(instance_id, opts \\ []) View Source
get_console_output(instance_id :: binary(), opts :: get_console_output_opts()) ::
  ExAws.Operation.Query.t()

Gets the console output for the specified instance.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_GetConsoleOutput.html

Examples:

iex> ExAws.EC2.get_console_output("i-123456")
%ExAws.Operation.Query{action: :get_console_output,
params: %{
  "Action" => "GetConsoleOutput",
  "InstanceId" => "i-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function get_password_data(instance_id, opts \\ []) View Source
get_password_data(instance_id :: binary(), opts :: get_password_data_opts()) ::
  ExAws.Operation.Query.t()

Retrieves the encrypted administrator password for an instance running Windows.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_GetPasswordData.html

Examples:

iex> ExAws.EC2.get_password_data("i-123456")
%ExAws.Operation.Query{action: :get_password_data,
params: %{
  "Action" => "GetPasswordData",
  "InstanceId" => "i-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function import_key_pair(key_name, public_key_material, opts \\ []) View Source
import_key_pair(
  key_name :: binary(),
  public_key_material :: binary(),
  opts :: import_key_pair_opts()
) :: ExAws.Operation.Query.t()

Imports the public key from an RSA key pair that you created with a third-party tool.

NOTE: public_key_material is base64-encoded binary data object.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html

Examples:

iex> ExAws.EC2.import_key_pair("my-key-pair", "Base64PublicKeyMaterial")
%ExAws.Operation.Query{action: :import_key_pair,
params: %{
  "Action" => "ImportKeyPair",
  "KeyName" => "my-key-pair",
  "PublicKeyMaterial" => "Base64PublicKeyMaterial",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_id_format(resource, use_long_ids) View Source
modify_id_format(resource :: binary(), use_long_ids :: boolean()) ::
  ExAws.Operation.Query.t()

Modifies the ID format for the specified resource on a per-region basis.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyIdFormat.html

Examples:

iex> ExAws.EC2.modify_id_format("instance", true)
%ExAws.Operation.Query{action: :modify_id_format,
params: %{
  "Action" => "ModifyIdFormat",
  "Resource" => "instance",
  "UseLongIds" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_image_attribute(image_id, opts \\ []) View Source
modify_image_attribute(
  image_id :: binary(),
  opts :: modify_image_attribute_opts()
) :: ExAws.Operation.Query.t()

Modifies the specified attribute of the specified AMI. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyImageAttribute.html

Examples:

iex> ExAws.EC2.modify_image_attribute("ami-123456", [attribute: "description"])
%ExAws.Operation.Query{action: :modify_image_attribute,
params: %{
  "Action" => "ModifyImageAttribute",
  "ImageId" => "ami-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_instance_attribute(instance_id, opts \\ []) View Source
modify_instance_attribute(
  instance_id :: binary(),
  opts :: modify_instance_attribute_opts()
) :: ExAws.Operation.Query.t()

Modifies the specified attribute of the specified instance. You can specify only one attribute at a time.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html

Examples:

iex> ExAws.EC2.modify_instance_attribute("i-123456", [instance_type: [value: "m1.small"]])
%ExAws.Operation.Query{action: :modify_instance_attribute,
params: %{
  "Action" => "ModifyInstanceAttribute",
  "InstanceId" => "i-123456",
  "InstanceType.Value" => "m1.small",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_snapshot_attribute(snapshot_id, opts \\ []) View Source
modify_snapshot_attribute(
  snapshot_id :: binary(),
  opts :: modify_snapshot_attribute_opts()
) :: ExAws.Operation.Query.t()

Adds or removes permission settings for the specified snapshot.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifySnapshotAttribute.html

Examples:

iex> ExAws.EC2.modify_snapshot_attribute("snap-123456")
%ExAws.Operation.Query{action: :modify_snapshot_attribute,
params: %{
  "Action" => "ModifySnapshotAttribute",
  "SnapshotId" => "snap-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.modify_snapshot_attribute("snap-123456", [attribute: "description"])
%ExAws.Operation.Query{action: :modify_snapshot_attribute,
params: %{
  "Action" => "ModifySnapshotAttribute",
  "SnapshotId" => "snap-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_subnet_attribute(subnet_id, opts \\ []) View Source
modify_subnet_attribute(
  subnet_id :: binary(),
  opts :: modify_subnet_attribute_opts()
) :: ExAws.Operation.Query.t()

Modifies a subnet attribute.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifySubnetAttribute.html

Examples:

iex> ExAws.EC2.modify_subnet_attribute("subnet-9d4a7b6c", [dry_run: true])
%ExAws.Operation.Query{action: :modify_subnet_attribute,
params: %{
  "Action" => "ModifySubnetAttribute",
  "SubnetId" => "subnet-9d4a7b6c",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_volume(volume_id, opts \\ []) View Source
modify_volume(volume_id :: binary(), opts :: modify_volume_opts()) ::
  ExAws.Operation.Query.t()

Modifies a specified volume.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyVolume.html

Examples:

iex> ExAws.EC2.modify_volume("vol-123456")
%ExAws.Operation.Query{action: :modify_volume,
params: %{
  "Action" => "ModifyVolume",
  "VolumeId" => "vol-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.modify_volume("vol-123456", [iops: 1000, size: 300, volume_type: "io1"])
%ExAws.Operation.Query{action: :modify_volume,
params: %{
  "Action" => "ModifyVolume",
  "VolumeId" => "vol-123456",
  "Iops" => 1000,
  "Size" => 300,
  "VolumeType" => "io1",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_volume_attribute(volume_id, opts \\ []) View Source
modify_volume_attribute(
  volume_id :: binary(),
  opts :: modify_volume_attribute_opts()
) :: ExAws.Operation.Query.t()

Modifies a volume attribute.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyVolumeAttribute.html

Examples:

iex> ExAws.EC2.modify_volume_attribute("vol-123456")
  %ExAws.Operation.Query{action: :modify_volume_attribute,
  params: %{
    "Action" => "ModifyVolumeAttribute",
    "VolumeId" => "vol-123456",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.modify_volume_attribute("vol-123456", auto_enable_io: [value: true])
  %ExAws.Operation.Query{action: :modify_volume_attribute,
  params: %{
    "Action" => "ModifyVolumeAttribute",
    "VolumeId" => "vol-123456",
    "AutoEnableIO.Value" => true,
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function modify_vpc_attribute(vpc_id, opts \\ []) View Source
modify_vpc_attribute(vpc_id :: binary(), opts :: modify_vpc_attribute_opts()) ::
  ExAws.Operation.Query.t()

Modifies the specified attribute of the specified VPC.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyVpcAttribute.html

Examples:

iex> ExAws.EC2.modify_vpc_attribute("vpc-123456", ["enable_dns_support": true])
  %ExAws.Operation.Query{action: :modify_vpc_attribute,
  params: %{
    "Action" => "ModifyVpcAttribute",
    "VpcId" => "vpc-123456",
    "EnableDnsSupport.Value" => true,
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function monitor_instances(instance_ids, opts \\ []) View Source
monitor_instances(
  instance_ids :: [binary(), ...],
  opts :: monitor_instances_opts()
) :: ExAws.Operation.Query.t()

Enables detailed monitoring for a running instance.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_MonitorInstances.html

Examples:

iex> ExAws.EC2.monitor_instances(["i-a1b2c3"])
%ExAws.Operation.Query{action: :monitor_instances,
params: %{
  "Action" => "MonitorInstances",
  "InstanceId.1" => "i-a1b2c3",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function reboot_instances(instance_ids, opts \\ []) View Source
reboot_instances(
  instance_ids :: [binary(), ...],
  opts :: reboot_instances_opts()
) :: ExAws.Operation.Query.t()

Requests a reboot of one or more instances. This operation is asynchronous; it only queues a request to reboot the specified instances.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RebootInstances.html

Examples:

iex> ExAws.EC2.reboot_instances(["i-123456"])
%ExAws.Operation.Query{action: :reboot_instances,
params: %{
  "Action" => "RebootInstances",
  "InstanceId.1" => "i-123456",
  "Version" => "2016-11-15"},
parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function register_image(name, opts \\ []) View Source
register_image(name :: binary(), opts :: register_image_opts()) ::
  ExAws.Operation.Query.t()

Registers an AMI. When you’re creating an AMI, this is the final step you must complete before you can launch an instance from the AMI.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RegisterImage.html

Examples:

iex> ExAws.EC2.register_image("Test")
%ExAws.Operation.Query{action: :register_image,
params: %{
  "Action" => "RegisterImage",
  "Name" => "Test",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex>
ExAws.EC2.register_image("Test", [block_device_mappings: [
[device_name: "/dev/sda1", ebs: [snapshot_id: "snap-1234567890abcdef0"]],
[device_name: "/dev/sdb",  ebs: [snapshot_id: "snap-1234567890abcdef1"]],
[device_name: "/dev/sdc",  ebs: [volume_size: 100]]
]])
%ExAws.Operation.Query{action: :register_image,
params: %{"
    Action" => "RegisterImage",
    "BlockDeviceMapping.1.DeviceName" => "/dev/sda1",
    "BlockDeviceMapping.1.Ebs.SnapshotId" => "snap-1234567890abcdef0",
    "BlockDeviceMapping.2.DeviceName" => "/dev/sdb",
    "BlockDeviceMapping.2.Ebs.SnapshotId" => "snap-1234567890abcdef1",
    "BlockDeviceMapping.3.DeviceName" => "/dev/sdc",
    "BlockDeviceMapping.3.Ebs.VolumeSize" => 100, "Name" => "Test",
    "Version" => "2016-11-15"}, parser: &ExAws.Utils.identity/2, path: "/",
 service: :ec2}
Link to this function report_instance_status(instance_ids, status, opts \\ []) View Source
report_instance_status(
  instance_ids :: [binary(), ...],
  status :: binary(),
  opts :: report_instance_status_opts()
) :: ExAws.Operation.Query.t()

Submits feedback about the status of an instance. The instance must be in the running state.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ReportInstanceStatus.html

Examples:

iex> ExAws.EC2.report_instance_status(["i-a1b2c3"], "ok")
%ExAws.Operation.Query{action: :report_instance_status,
params: %{
  "Action" => "ReportInstanceStatus",
  "InstanceId.1" => "i-a1b2c3",
  "Status" => "ok",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function reset_image_attribute(image_id, attribute, opts \\ []) View Source
reset_image_attribute(
  image_id :: binary(),
  attribute :: binary(),
  opts :: reset_image_attribute_opts()
) :: ExAws.Operation.Query.t()

Resets an attribute of an AMI to its default value. Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ResetImageAttribute.html

NOTE: You can currently only reset the launchPermission attribute. Please refer to the doc in case something has changed.

Examples:

iex> ExAws.EC2.reset_image_attribute("ami-1234567", "launchPermission")
%ExAws.Operation.Query{action: :reset_image_attribute,
params: %{
  "Action" => "ResetImageAttribute",
  "ImageId" => "ami-1234567",
  "Attribute" => "launchPermission",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function reset_instance_attribute(instance_id, attribute, opts \\ []) View Source
reset_instance_attribute(
  instance_id :: binary(),
  attribute :: binary(),
  opts :: reset_instance_attribute_opts()
) :: ExAws.Operation.Query.t()

Resets an attribute of an instance to its default value. To reset the kernel or ramdisk, the instance must be in a stopped state. To reset the SourceDestCheck, the instance can be either running or stopped.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ResetInstanceAttribute.html

Examples:

iex> ExAws.EC2.reset_instance_attribute("i-123456", "description")
%ExAws.Operation.Query{action: :reset_instance_attribute,
params: %{
  "Action" => "ResetInstanceAttribute",
  "InstanceId" => "i-123456",
  "Attribute" => "description",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function reset_snapshot_attribute(snapshot_id, attribute, opts \\ []) View Source
reset_snapshot_attribute(
  snapshot_id :: binary(),
  attribute :: binary(),
  opts :: reset_snapshot_attribute_opts()
) :: ExAws.Operation.Query.t()

Resets permission settings for the specified snapshot.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ResetSnapshotAttribute.html

Examples:

iex> ExAws.EC2.reset_snapshot_attribute("snap-123456", "description")
  %ExAws.Operation.Query{action: :reset_snapshot_attribute,
  params: %{
    "Action" => "ResetSnapshotAttribute",
    "SnapshotId" => "snap-123456",
    "Attribute" => "description",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

  iex> ExAws.EC2.reset_snapshot_attribute("snap-123456", "description", [dry_run: true])
  %ExAws.Operation.Query{action: :reset_snapshot_attribute,
  params: %{
    "Action" => "ResetSnapshotAttribute",
    "SnapshotId" => "snap-123456",
    "Attribute" => "description",
    "DryRun" => true,
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function revoke_security_group_egress(group_id, opts \\ []) View Source
revoke_security_group_egress(
  group_id :: binary(),
  opts :: revoke_security_group_egress_opts()
) :: ExAws.Operation.Query.t()

Removes one or more egress rules from a security group for EC2-VPC.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RevokeSecurityGroupEgress.html

Examples:

iex> ExAws.EC2.revoke_security_group_egress("sg-123456", [
   ...>  cidr_ip: "10.0.0.2", dry_run: true, from_port: 22, to_port: 22
   ...> ])
   %ExAws.Operation.Query{action: :revoke_security_group_egress,
   params: %{
     "Action" => "RevokeSecurityGroupEgress",
     "GroupId" => "sg-123456",
     "CidrIp" => "10.0.0.2",
     "DryRun" => true,
     "FromPort" => 22,
     "ToPort" => 22,
     "Version" => "2016-11-15"
   }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function revoke_security_group_ingress(opts \\ []) View Source
revoke_security_group_ingress(opts :: revoke_security_group_ingress_opts()) ::
  ExAws.Operation.Query.t()

Removes one or more ingress rules from a security group. The values that you specify in the revoke request (for example, ports) must match the existing rule’s values for the rule to be removed.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RevokeSecurityGroupIngress.html

Examples:

iex> ExAws.EC2.revoke_security_group_ingress([ip_protocol: "tcp",
  ...> source_security_group_name: "websrv", source_security_group_owner_id: "test_id"])
  %ExAws.Operation.Query{action: :revoke_security_group_ingress,
  params: %{
    "Action" => "RevokeSecurityGroupIngress",
    "IpProtocol" => "tcp",
    "SourceSecurityGroupName" => "websrv",
    "SourceSecurityGroupOwnerId" => "test_id",
    "Version" => "2016-11-15"
  }, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function run_instances(image_id, min_count, max_count, opts \\ []) View Source
run_instances(
  image_id :: binary(),
  min_count :: integer(),
  max_count :: integer(),
  opts :: run_instances_opts()
) :: ExAws.Operation.Query.t()

Launches the specified number of instances using an AMI for which you have permissions.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html

Examples:

iex> ExAws.EC2.run_instances("ami-123456", 3, 3,
...> [block_device_mappings: [
...>  [device_name: "/dev/sdc", virtual_name: "ephemeral10"],
...>  [device_name: "/dev/sdd", virtual_name: "ephemeral11"],
...>  [device_name: "/dev/sdf", ebs: [delete_on_termination: true, volume_size: 100]]
...> ]])
%ExAws.Operation.Query{action: :run_instances,
params: %{
  "Action" => "RunInstances",
  "ImageId" => "ami-123456",
  "MinCount" => 3,
  "MaxCount" => 3,
  "BlockDeviceMapping.1.DeviceName" => "/dev/sdc",
  "BlockDeviceMapping.1.VirtualName" => "ephemeral10",
  "BlockDeviceMapping.2.DeviceName" => "/dev/sdd",
  "BlockDeviceMapping.2.VirtualName" => "ephemeral11",
  "BlockDeviceMapping.3.DeviceName" => "/dev/sdf",
  "BlockDeviceMapping.3.Ebs.DeleteOnTermination" => true,
  "BlockDeviceMapping.3.Ebs.VolumeSize" => 100,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function start_instances(instance_ids, opts \\ []) View Source
start_instances(instance_ids :: [binary(), ...], opts :: start_instances_opts()) ::
  ExAws.Operation.Query.t()

Starts an Amazon EBS-backed AMI that was previously stopped.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_StartInstances.html

Examples:

iex> ExAws.EC2.start_instances(["i-123456"])
%ExAws.Operation.Query{action: :start_instances,
params: %{
  "Action" => "StartInstances",
  "InstanceId.1" => "i-123456",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function stop_instances(instance_ids, opts \\ []) View Source
stop_instances(instance_ids :: [binary(), ...], opts :: stop_instances_opts()) ::
  ExAws.Operation.Query.t()

Stops an Amazon EBS-backed AMI that was previously started.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_StopInstances.html

Examples:

iex> ExAws.EC2.stop_instances(["i-123456"], [force: true])
%ExAws.Operation.Query{action: :stop_instances,
params: %{
  "Action" => "StopInstances",
  "InstanceId.1" => "i-123456",
  "Force" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function terminate_instances(instance_ids, opts \\ []) View Source
terminate_instances(
  instance_ids :: [binary(), ...],
  opts :: terminate_instances_opts()
) :: ExAws.Operation.Query.t()

Shuts down one or more instances. Terminated instances remain visible after termination (for approximately one hour).

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_TerminateInstances.html

Examples:

iex> ExAws.EC2.terminate_instances(["i-123456", "i-987654"])
%ExAws.Operation.Query{action: :terminate_instances,
params: %{
  "Action" => "TerminateInstances",
  "InstanceId.1" => "i-123456",
  "InstanceId.2" => "i-987654",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}

iex> ExAws.EC2.terminate_instances(["i-123456"], [dry_run: true])
%ExAws.Operation.Query{action: :terminate_instances,
params: %{
  "Action" => "TerminateInstances",
  "InstanceId.1" => "i-123456",
  "DryRun" => true,
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}
Link to this function unmonitor_instances(instance_ids, opts \\ []) View Source
unmonitor_instances(
  instance_ids :: [binary(), ...],
  opts :: unmonitor_instances_opts()
) :: ExAws.Operation.Query.t()

Disables detailed monitoring for a running instance.

Doc: http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_UnmonitorInstances.html

Examples:

iex> ExAws.EC2.unmonitor_instances(["i-a1b2c3"])
%ExAws.Operation.Query{action: :unmonitor_instances,
params: %{
  "Action" => "UnmonitorInstances",
  "InstanceId.1" => "i-a1b2c3",
  "Version" => "2016-11-15"
}, parser: &ExAws.Utils.identity/2, path: "/", service: :ec2}