steampunk.aws.ec2_vpc_address_info (0.9.0) — module

List EC2 VPC addresses

Authors: Manca Bizjak (@mancabizjak), Aljaz Kosir (@aljazkosir), Saso Stanovnik (@sstanovnik), Miha Dolinar (@mdolinar), Tadej Borovsak (@tadeboro)

preview | supported by XLAB Steampunk

Install collection

Install with ansible-galaxy collection install steampunk.aws:==0.9.0


Add to requirements.yml

  collections:
    - name: steampunk.aws
      version: 0.9.0

Description

Retrieve information about AWS EC2 VPC addresses.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: List all VPC addresses in a region
  ec2_vpc_address_info:
  register: result
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: List specific VPC addresses
  ec2_vpc_address_info:
    ips:
      - 3.21.120.93
      - 3.22.108.97
  register: result

Inputs

    
ips:
    description: Limit results to the specified VPC addresses only
    elements: str
    type: list

auth:
    description:
    - Parameters for authenticating with the AWS service. Each of them may be defined
      via environment variables.
    suboptions:
      access_key:
        description:
        - The AWS access key ID. If not set, the value of the AWS_ACCESS_KEY environment
          variable will be checked.
        - Mutually exclusive with I(profile).
        required: false
        type: str
      profile:
        description:
        - The name of the AWS profile configured with C(aws configure).
        - Can be used instead of explicitly specifying your access credentials and region.
        - Use C(default) to use the default profile.
        - Mutually exclusive with I(access_key) and I(secret_key).
        required: false
        type: str
      region:
        description:
        - The name of the AWS region.
        - If not set, the value of the AWS_REGION environment variable will be checked.
        - If you set a I(profile) that specifies a default region, that region is used
          and you can omit this parameter. Use this parameter to override the profile's
          default region.
        type: str
      secret_key:
        description:
        - The AWS secret access key. If not set, the value of the AWS_SECRET_KEY environment
          variable will be checked.
        - Mutually exclusive with I(profile).
        required: false
        type: str
      url:
        description:
        - The URL to the AWS service related to the resource. By default, this is automatically
          determined through the region parameter.
        - If not set explicitly, the value of the AWS_<SERVICE>_URL environment variable
          will be used.
        - The services currently supported are EC2 and S3.
        required: false
        type: str
    type: dict

Outputs

objects:
  contains:
    allocation_id:
      description: Allocation ID of the VPC address.
      returned: always
      sample: eipalloc-04bed816a62ae64b1
      type: str
    instance:
      description: ID of the instance to which the network interface associated with
        the VPC address is attached (if any).
      returned: always
      sample: i-0c79884ded545df1a, None
      type: str
    ip:
      description: The Elastic IP address.
      returned: always
      sample: 3.20.251.70
      type: str
    network_interface:
      description: ID of the network interface VPC address is associated with.
      returned: always
      sample: eni-0a6d3406ea74e7bab
      type: str
    tags:
      description: Tags associated with the internet gateway.
      returned: always
      sample:
        Name: my-vpc-address
      type: dict
  description:
  - A list of objects representing EC2 VPC addresses.
  returned: success
  type: list

See also