Skip to content

Commit

Permalink
Fix sanity failures
Browse files Browse the repository at this point in the history
  • Loading branch information
GomathiselviS committed May 14, 2024
1 parent b86dd5b commit 15a89d4
Show file tree
Hide file tree
Showing 7 changed files with 80 additions and 117 deletions.
7 changes: 4 additions & 3 deletions plugins/modules/ec2_snapshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@
sample: snap-01234567
snapshots:
description: List of snapshots.
returned: always
type: list
elements: dict
contains:
Expand Down Expand Up @@ -217,13 +218,13 @@
sample: snap-1234
start_time:
description: Time this snapshot was started. This is the same for all snapshots initiated by the same request.
type: datetime
type: str
returned: always
sample: 2024-05-07T14:29:24.523000+00:00
sample: "2024-05-07T14:29:24.523000+00:00"
state:
description: Current state of the snapshot.
type: str
return: always
returned: always
sample: pending
tags:
description: Tags associated with this snapshot.
Expand Down
2 changes: 1 addition & 1 deletion plugins/modules/ec2_snapshot_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
sample:
storage_tier:
description: The storage tier in which the snapshot is stored.
type: string
type: str
returned: always
sample: standard
tags:
Expand Down
1 change: 1 addition & 0 deletions plugins/modules/ec2_spot_instance.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,7 @@
cancelled_spot_request:
description: The spot instance request details that has been cancelled
type: str
returned: when cancellation is successful
sample: 'Spot requests with IDs: sir-1234abcd have been cancelled'
"""

Expand Down
116 changes: 58 additions & 58 deletions plugins/modules/ec2_vol.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,64 +225,64 @@
type: dict
contains:
attachment_set:
description:
- Information about the volume attachments.
- This was changed in version 2.0.0 from a dictionary to a list of dictionaries.
type: list
elements: dict
sample: [{
"attach_time": "2015-10-23T00:22:29.000Z",
"deleteOnTermination": "false",
"device": "/dev/sdf",
"instance_id": "i-8356263c",
"status": "attached"
}]
create_time:
description: The time stamp when volume creation was initiated.
type: str
sample: "2015-10-21T14:36:08.870Z"
encrypted:
description: Indicates whether the volume is encrypted.
type: bool
sample: False
id:
description: The ID of the volume.
type: str
sample: "vol-35b333d9"
iops:
description: The number of I/O operations per second (IOPS) that the volume supports.
type: int
sample: null
size:
description: The size of the volume, in GiBs.
type: int
sample: 1
snapshot_id:
description: The snapshot from which the volume was created, if applicable.
type: str
sample: ""
status:
description: The volume state.
type: str
sample: "in-use"
tags:
description: Any tags assigned to the volume.
type: dict
sample: {
env: "dev"
}
type:
description: The volume type. This can be gp2, io1, st1, sc1, or standard.
type: str
sample: "standard"
zone:
description: The Availability Zone of the volume.
type: str
sample: "us-east-1b"
throughput:
description: The throughput that the volume supports, in MiB/s.
type: int
sample: 131
description:
- Information about the volume attachments.
- This was changed in version 2.0.0 from a dictionary to a list of dictionaries.
type: list
elements: dict
sample: [{
"attach_time": "2015-10-23T00:22:29.000Z",
"deleteOnTermination": "false",
"device": "/dev/sdf",
"instance_id": "i-8356263c",
"status": "attached"
}]
create_time:
description: The time stamp when volume creation was initiated.
type: str
sample: "2015-10-21T14:36:08.870Z"
encrypted:
description: Indicates whether the volume is encrypted.
type: bool
sample: False
id:
description: The ID of the volume.
type: str
sample: "vol-35b333d9"
iops:
description: The number of I/O operations per second (IOPS) that the volume supports.
type: int
sample: null
size:
description: The size of the volume, in GiBs.
type: int
sample: 1
snapshot_id:
description: The snapshot from which the volume was created, if applicable.
type: str
sample: ""
status:
description: The volume state.
type: str
sample: "in-use"
tags:
description: Any tags assigned to the volume.
type: dict
sample: {
env: "dev"
}
type:
description: The volume type. This can be gp2, io1, st1, sc1, or standard.
type: str
sample: "standard"
zone:
description: The Availability Zone of the volume.
type: str
sample: "us-east-1b"
throughput:
description: The throughput that the volume supports, in MiB/s.
type: int
sample: 131
"""

import time
Expand Down
45 changes: 0 additions & 45 deletions plugins/modules/ec2_vpc_endpoint.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,51 +244,6 @@
description: The ID of the VPC.
returned: always
type: str
sample: [
{
"creation_timestamp": "2017-02-20T05:04:15+00:00",
"dns_entries": [],
"dns_options": {
"dns_record_ip_type": "ipv4"
},
"groups": [
{
"group_id": "sg-03196a047b95d36ad",
"group_name": "default"
}
],
"ip_address_type": "ipv4",
"network_interface_ids": [],
"owner_id": "721066863947",
"policy_document": {
"Id": "Policy1450910922815",
"Statement": [
{
"Action": "s3:*",
"Effect": "Allow",
"Principal": "*",
"Resource": [
"arn:aws:s3:::*/*",
"arn:aws:s3:::*"
],
"Sid": "Stmt1450910920641"
}
],
"Version": "2012-10-17"
},
"private_dns_enabled": false,
"requester_managed"s: false,
"route_table_ids": [],
"service_name": "io.spotinst.vpce.us-east-1.linkapi",
"state": "pendingAcceptance",
"subnet_ids": [],
"tags": [],
"vpc_endpoint_id": "vpce-1234",
"vpc_endpoint_type": "Interface",
"vpc_id": "vpc-0ee1a4b203c587ffa"
"route_table_ids": [],
}
]
"""

import datetime
Expand Down
13 changes: 8 additions & 5 deletions plugins/modules/ec2_vpc_subnet.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
sample: false
enable_dns64:
description:
- Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations.
- Indicates whether DNS queries made should return synthetic IPv6 addresses for IPv4-only destinations.
type: bool
sample: false
ipv6_association_id:
Expand Down Expand Up @@ -215,21 +215,24 @@
returned: always
type: str
map_customer_owned_ip_on_launch:
description: Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives a customer-owned IPv4 address.
description:
- Indicates whether a network interface receives a customer-owned IPv4 address.
type: bool
sample: flase
owner_id:
description: The ID of the Amazon Web Services account that owns the subnet.
type: str
sample: 12344567
private_dns_name_options_on_launch:
description: The type of hostnames to assign to instances in the subnet at launch. An instance hostname is based on the IPv4 address or ID of the instance.
description:
- The type of hostnames to assign to instances in the subnet at launch.
- An instance hostname is based on the IPv4 address or ID of the instance.
type: dict
sample: "{
sample: {
"enable_resource_name_dns_a_record": false,
"enable_resource_name_dns_aaaa_record": false,
"hostname_type": "ip-name"
}"
}
subnet_arn:
description: The Amazon Resource Name (ARN) of the subnet.
type: str
Expand Down
13 changes: 8 additions & 5 deletions plugins/modules/ec2_vpc_subnet_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
sample: false
enable_dns64:
description:
- Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet should return synthetic IPv6 addresses for IPv4-only destinations.
- Indicates whether DNS queries made should return synthetic IPv6 addresses for IPv4-only destinations.
type: bool
sample: false
ipv6_association_id:
Expand Down Expand Up @@ -173,21 +173,24 @@
returned: always
type: str
map_customer_owned_ip_on_launch:
description: Indicates whether a network interface created in this subnet (including a network interface created by RunInstances) receives a customer-owned IPv4 address.
description:
- Indicates whether a network interface receives a customer-owned IPv4 address.
type: bool
sample: flase
owner_id:
description: The ID of the Amazon Web Services account that owns the subnet.
type: str
sample: 12344567
private_dns_name_options_on_launch:
description: The type of hostnames to assign to instances in the subnet at launch. An instance hostname is based on the IPv4 address or ID of the instance.
description:
- The type of hostnames to assign to instances in the subnet at launch.
- An instance hostname is based on the IPv4 address or ID of the instance.
type: dict
sample: "{
sample: {
"enable_resource_name_dns_a_record": false,
"enable_resource_name_dns_aaaa_record": false,
"hostname_type": "ip-name"
}"
}
subnet_arn:
description: The Amazon Resource Name (ARN) of the subnet.
type: str
Expand Down

0 comments on commit 15a89d4

Please sign in to comment.