awspec 1.21.1 → 1.24.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +2 -0
- data/doc/_resource_types/eks_nodegroup.md +14 -0
- data/doc/_resource_types/s3_bucket.md +8 -0
- data/doc/_resource_types/vpc_endpoints.md +70 -0
- data/doc/resource_types.md +133 -27
- data/lib/awspec/generator/doc/type/eks_nodegroup.rb +19 -0
- data/lib/awspec/generator/doc/type/vpc_endpoints.rb +17 -0
- data/lib/awspec/generator/spec/iam_group.rb +1 -1
- data/lib/awspec/generator/spec/iam_role.rb +1 -1
- data/lib/awspec/generator/spec/iam_user.rb +1 -1
- data/lib/awspec/generator/spec/s3_bucket.rb +4 -0
- data/lib/awspec/helper/finder.rb +4 -1
- data/lib/awspec/helper/finder/eks.rb +5 -0
- data/lib/awspec/helper/finder/s3.rb +11 -0
- data/lib/awspec/helper/finder/vpc_endpoints.rb +15 -0
- data/lib/awspec/helper/type.rb +2 -2
- data/lib/awspec/stub/eks_nodegroup.rb +16 -0
- data/lib/awspec/stub/s3_bucket.rb +3 -0
- data/lib/awspec/stub/vpc_endpoints.rb +64 -0
- data/lib/awspec/type/eks_nodegroup.rb +30 -0
- data/lib/awspec/type/iam_group.rb +1 -1
- data/lib/awspec/type/iam_role.rb +1 -1
- data/lib/awspec/type/iam_user.rb +1 -1
- data/lib/awspec/type/kms.rb +1 -1
- data/lib/awspec/type/s3_bucket.rb +5 -0
- data/lib/awspec/type/vpc_endpoints.rb +43 -0
- data/lib/awspec/version.rb +1 -1
- metadata +11 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ccbb248dd9ff83f422a5d62d6463be302ee629861e3a29ebfb3b062313ccca4f
|
4
|
+
data.tar.gz: 14fb693105dafceb27095c0ec2af853422f5ed92ee877a69df66a4679a6acad1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4d580f1de54fd8a7b5106d83f4b5b7320f2679d5eb58ef6d73009fb340bc7a0193b78f4f10d16601d9dacb5658a94936efd0af40699ef781229eef54c645e7f3
|
7
|
+
data.tar.gz: bf0f3fa1ab69f5945307284f1b3460bfadb9571c892601418dbfaee6536cd4269fdbc4b1c1631b438098dace53aeb49bdaa59773bc03d759ee3c709970c5b235
|
data/.travis.yml
CHANGED
@@ -0,0 +1,14 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe eks_nodegroup('my-eks-nodegroup'), cluster: 'my-cluster' do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
### be_active, be_creating
|
9
|
+
|
10
|
+
```ruby
|
11
|
+
describe eks('my-eks-nodegroup'), cluster: 'my-cluster' do
|
12
|
+
it { should be_active }
|
13
|
+
end
|
14
|
+
```
|
@@ -0,0 +1,70 @@
|
|
1
|
+
### exist
|
2
|
+
|
3
|
+
```ruby
|
4
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
5
|
+
it { should exist }
|
6
|
+
end
|
7
|
+
```
|
8
|
+
|
9
|
+
describe vpc_endpoints('vpce-05907f23265b25f20'), region: $tfvars["region"]["value"] do
|
10
|
+
it { should exist }
|
11
|
+
it { should be_available }
|
12
|
+
it { should have_subnet('subnet-040e19eabf3226f99') }
|
13
|
+
it { should belong_to_vpc('vpc-00af9dcc0134b48e0') }
|
14
|
+
its(:private_dns_enabled) { should eq true }
|
15
|
+
its(:vpc_endpoint_type) { should eq 'Interface' }
|
16
|
+
its(:service_name) { should eq 'com.amazonaws.eu-west-1.codebuild' }
|
17
|
+
end
|
18
|
+
|
19
|
+
### be_pendingacceptance, be_pending, be_available, be_deleting, be_deleted, be_rejected, be_failed, be_expired
|
20
|
+
|
21
|
+
```ruby
|
22
|
+
describe ami('my-ami') do
|
23
|
+
it { should be_available }
|
24
|
+
end
|
25
|
+
```
|
26
|
+
|
27
|
+
### belong_to_vpc
|
28
|
+
|
29
|
+
```ruby
|
30
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
31
|
+
it { should belong_to_vpc('my-vpc') }
|
32
|
+
end
|
33
|
+
```
|
34
|
+
|
35
|
+
### have_route_table
|
36
|
+
|
37
|
+
```ruby
|
38
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
39
|
+
it { should have_route_table('rtb-abc123') }
|
40
|
+
end
|
41
|
+
```
|
42
|
+
|
43
|
+
### have_subnet
|
44
|
+
|
45
|
+
```ruby
|
46
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
47
|
+
it { should have_subnet('subnet-abc123') }
|
48
|
+
end
|
49
|
+
```
|
50
|
+
|
51
|
+
### have_tag
|
52
|
+
|
53
|
+
```ruby
|
54
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
55
|
+
it { should have_tag('env').value('dev') }
|
56
|
+
end
|
57
|
+
```
|
58
|
+
|
59
|
+
### advanced
|
60
|
+
|
61
|
+
`vpc_endpoints` can use `Aws::EC2::Types::VpcEndpoint` resource (see https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/EC2/Types/VpcEndpoint.html).
|
62
|
+
|
63
|
+
```ruby
|
64
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
65
|
+
its(:private_dns_enabled) { should eq true }
|
66
|
+
its(:vpc_endpoint_type) { should eq 'Interface' }
|
67
|
+
its(:service_name) { should eq 'com.amazonaws.eu-west-1.codebuild' }
|
68
|
+
end
|
69
|
+
```
|
70
|
+
|
data/doc/resource_types.md
CHANGED
@@ -34,6 +34,7 @@
|
|
34
34
|
| [efs](#efs)
|
35
35
|
| [eip](#eip)
|
36
36
|
| [eks](#eks)
|
37
|
+
| [eks_nodegroup](#eks_nodegroup)
|
37
38
|
| [elasticache](#elasticache)
|
38
39
|
| [elasticache_cache_parameter_group](#elasticache_cache_parameter_group)
|
39
40
|
| [elasticsearch](#elasticsearch)
|
@@ -76,6 +77,7 @@
|
|
76
77
|
| [subnet](#subnet)
|
77
78
|
| [transit_gateway](#transit_gateway)
|
78
79
|
| [vpc](#vpc)
|
80
|
+
| [vpc_endpoints](#vpc_endpoints)
|
79
81
|
| [vpn_connection](#vpn_connection)
|
80
82
|
| [vpn_gateway](#vpn_gateway)
|
81
83
|
| [waf_web_acl](#waf_web_acl)
|
@@ -166,7 +168,7 @@ describe alb('my-alb') do
|
|
166
168
|
end
|
167
169
|
```
|
168
170
|
|
169
|
-
### its(:load_balancer_arn), its(:dns_name), its(:canonical_hosted_zone_id), its(:created_time), its(:load_balancer_name), its(:scheme), its(:vpc_id), its(:type), its(:security_groups), its(:ip_address_type)
|
171
|
+
### its(:load_balancer_arn), its(:dns_name), its(:canonical_hosted_zone_id), its(:created_time), its(:load_balancer_name), its(:scheme), its(:vpc_id), its(:type), its(:security_groups), its(:ip_address_type), its(:customer_owned_ipv_4_pool)
|
170
172
|
## <a name="alb_listener">alb_listener</a>
|
171
173
|
|
172
174
|
AlbListener resource type.
|
@@ -246,7 +248,7 @@ end
|
|
246
248
|
```
|
247
249
|
|
248
250
|
|
249
|
-
### its(:target_group_arn), its(:target_group_name), its(:protocol), its(:port), its(:vpc_id), its(:health_check_protocol), its(:health_check_port), its(:health_check_enabled), its(:health_check_interval_seconds), its(:health_check_timeout_seconds), its(:healthy_threshold_count), its(:unhealthy_threshold_count), its(:health_check_path), its(:load_balancer_arns), its(:target_type)
|
251
|
+
### its(:target_group_arn), its(:target_group_name), its(:protocol), its(:port), its(:vpc_id), its(:health_check_protocol), its(:health_check_port), its(:health_check_enabled), its(:health_check_interval_seconds), its(:health_check_timeout_seconds), its(:healthy_threshold_count), its(:unhealthy_threshold_count), its(:health_check_path), its(:load_balancer_arns), its(:target_type), its(:protocol_version)
|
250
252
|
## <a name="ami">ami</a>
|
251
253
|
|
252
254
|
AMI resource type.
|
@@ -271,7 +273,7 @@ end
|
|
271
273
|
|
272
274
|
### have_tag
|
273
275
|
|
274
|
-
### its(:architecture), its(:creation_date), its(:image_id), its(:image_location), its(:image_type), its(:public), its(:kernel_id), its(:owner_id), its(:platform), its(:platform_details), its(:usage_operation), its(:ramdisk_id), its(:state), its(:description), its(:ena_support), its(:hypervisor), its(:image_owner_alias), its(:name), its(:root_device_name), its(:root_device_type), its(:sriov_net_support), its(:state_reason), its(:virtualization_type)
|
276
|
+
### its(:architecture), its(:creation_date), its(:image_id), its(:image_location), its(:image_type), its(:public), its(:kernel_id), its(:owner_id), its(:platform), its(:platform_details), its(:usage_operation), its(:ramdisk_id), its(:state), its(:description), its(:ena_support), its(:hypervisor), its(:image_owner_alias), its(:name), its(:root_device_name), its(:root_device_type), its(:sriov_net_support), its(:state_reason), its(:virtualization_type), its(:boot_mode)
|
275
277
|
### :unlock: Advanced use
|
276
278
|
|
277
279
|
`ami` can use `Aws::EC2::Image` resource (see http://docs.aws.amazon.com/sdkforruby/api/Aws/EC2/Image.html).
|
@@ -296,7 +298,7 @@ end
|
|
296
298
|
|
297
299
|
### have_path
|
298
300
|
|
299
|
-
### its(:id), its(:name), its(:description), its(:created_date), its(:version), its(:warnings), its(:binary_media_types), its(:minimum_compression_size), its(:api_key_source), its(:policy), its(:tags)
|
301
|
+
### its(:id), its(:name), its(:description), its(:created_date), its(:version), its(:warnings), its(:binary_media_types), its(:minimum_compression_size), its(:api_key_source), its(:policy), its(:tags), its(:disable_execute_api_endpoint)
|
300
302
|
## <a name="autoscaling_group">autoscaling_group</a>
|
301
303
|
|
302
304
|
AutoscalingGroup resource type.
|
@@ -358,7 +360,7 @@ describe autoscaling_group('my-auto-scaling-group') do
|
|
358
360
|
end
|
359
361
|
```
|
360
362
|
|
361
|
-
### its(:auto_scaling_group_name), its(:auto_scaling_group_arn), its(:launch_configuration_name), its(:launch_template), its(:mixed_instances_policy), its(:min_size), its(:max_size), its(:desired_capacity), its(:default_cooldown), its(:availability_zones), its(:load_balancer_names), its(:target_group_arns), its(:health_check_type), its(:health_check_grace_period), its(:created_time), its(:placement_group), its(:vpc_zone_identifier), its(:enabled_metrics), its(:status), its(:termination_policies), its(:new_instances_protected_from_scale_in), its(:service_linked_role_arn), its(:max_instance_lifetime)
|
363
|
+
### its(:auto_scaling_group_name), its(:auto_scaling_group_arn), its(:launch_configuration_name), its(:launch_template), its(:mixed_instances_policy), its(:min_size), its(:max_size), its(:desired_capacity), its(:default_cooldown), its(:availability_zones), its(:load_balancer_names), its(:target_group_arns), its(:health_check_type), its(:health_check_grace_period), its(:created_time), its(:placement_group), its(:vpc_zone_identifier), its(:enabled_metrics), its(:status), its(:termination_policies), its(:new_instances_protected_from_scale_in), its(:service_linked_role_arn), its(:max_instance_lifetime), its(:capacity_rebalance), its(:warm_pool_configuration), its(:warm_pool_size)
|
362
364
|
## <a name="batch_compute_environment">batch_compute_environment</a>
|
363
365
|
|
364
366
|
BatchComputeEnvironment resource type.
|
@@ -397,7 +399,7 @@ end
|
|
397
399
|
|
398
400
|
### be_unmanaged
|
399
401
|
|
400
|
-
### its(:compute_environment_name), its(:compute_environment_arn), its(:ecs_cluster_arn), its(:type), its(:state), its(:status), its(:status_reason), its(:service_role)
|
402
|
+
### its(:compute_environment_name), its(:compute_environment_arn), its(:ecs_cluster_arn), its(:tags), its(:type), its(:state), its(:status), its(:status_reason), its(:service_role)
|
401
403
|
## <a name="batch_job_definition">batch_job_definition</a>
|
402
404
|
|
403
405
|
BatchJobDefinition resource type.
|
@@ -410,7 +412,7 @@ describe batch_job_definition('my-batch-job-definition') do
|
|
410
412
|
end
|
411
413
|
```
|
412
414
|
|
413
|
-
### its(:job_definition_name), its(:job_definition_arn), its(:revision), its(:status), its(:type), its(:parameters), its(:retry_strategy), its(:timeout), its(:node_properties)
|
415
|
+
### its(:job_definition_name), its(:job_definition_arn), its(:revision), its(:status), its(:type), its(:parameters), its(:retry_strategy), its(:timeout), its(:node_properties), its(:tags), its(:propagate_tags), its(:platform_capabilities)
|
414
416
|
## <a name="batch_job_queue">batch_job_queue</a>
|
415
417
|
|
416
418
|
BatchJobQueue resource type.
|
@@ -436,7 +438,7 @@ describe batch_job_queue('my-batch-job-queue') do
|
|
436
438
|
end
|
437
439
|
```
|
438
440
|
|
439
|
-
### its(:job_queue_name), its(:job_queue_arn), its(:state), its(:status), its(:status_reason), its(:priority)
|
441
|
+
### its(:job_queue_name), its(:job_queue_arn), its(:state), its(:status), its(:status_reason), its(:priority), its(:tags)
|
440
442
|
## <a name="cloudformation_stack">cloudformation_stack</a>
|
441
443
|
|
442
444
|
CloudformationStack resource type.
|
@@ -742,7 +744,7 @@ describe codedeploy_deployment_group('my-codedeploy-deployment-group'), applicat
|
|
742
744
|
end
|
743
745
|
```
|
744
746
|
|
745
|
-
### its(:application_name), its(:deployment_group_id), its(:deployment_group_name), its(:deployment_config_name), its(:on_premises_instance_tag_filters), its(:service_role_arn), its(:target_revision), its(:trigger_configurations), its(:alarm_configuration), its(:deployment_style), its(:load_balancer_info), its(:last_successful_deployment), its(:last_attempted_deployment), its(:ec2_tag_set), its(:on_premises_tag_set), its(:compute_platform), its(:ecs_services)
|
747
|
+
### its(:application_name), its(:deployment_group_id), its(:deployment_group_name), its(:deployment_config_name), its(:on_premises_instance_tag_filters), its(:service_role_arn), its(:target_revision), its(:trigger_configurations), its(:alarm_configuration), its(:deployment_style), its(:outdated_instances_strategy), its(:load_balancer_info), its(:last_successful_deployment), its(:last_attempted_deployment), its(:ec2_tag_set), its(:on_premises_tag_set), its(:compute_platform), its(:ecs_services)
|
746
748
|
## <a name="cognito_identity_pool">cognito_identity_pool</a>
|
747
749
|
|
748
750
|
CognitoIdentityPool resource type.
|
@@ -930,7 +932,7 @@ end
|
|
930
932
|
```
|
931
933
|
|
932
934
|
|
933
|
-
### its(:availability_zone), its(:create_time), its(:encrypted), its(:kms_key_id), its(:outpost_arn), its(:size), its(:snapshot_id), its(:state), its(:volume_id), its(:iops), its(:volume_type), its(:fast_restored), its(:multi_attach_enabled)
|
935
|
+
### its(:availability_zone), its(:create_time), its(:encrypted), its(:kms_key_id), its(:outpost_arn), its(:size), its(:snapshot_id), its(:state), its(:volume_id), its(:iops), its(:volume_type), its(:fast_restored), its(:multi_attach_enabled), its(:throughput)
|
934
936
|
### :unlock: Advanced use
|
935
937
|
|
936
938
|
`ebs` can use `Aws::EC2::Volume` resource (see http://docs.aws.amazon.com/sdkforruby/api/Aws/EC2/Volume.html).
|
@@ -1116,7 +1118,7 @@ end
|
|
1116
1118
|
```
|
1117
1119
|
|
1118
1120
|
|
1119
|
-
### its(:ami_launch_index), its(:image_id), its(:instance_id), its(:instance_type), its(:kernel_id), its(:key_name), its(:launch_time), its(:monitoring), its(:placement), its(:platform), its(:private_dns_name), its(:private_ip_address), its(:product_codes), its(:public_dns_name), its(:public_ip_address), its(:ramdisk_id), its(:state_transition_reason), its(:subnet_id), its(:vpc_id), its(:architecture), its(:client_token), its(:ebs_optimized), its(:ena_support), its(:hypervisor), its(:instance_lifecycle), its(:elastic_gpu_associations), its(:elastic_inference_accelerator_associations), its(:outpost_arn), its(:root_device_name), its(:root_device_type), its(:source_dest_check), its(:spot_instance_request_id), its(:sriov_net_support), its(:state_reason), its(:virtualization_type), its(:cpu_options), its(:capacity_reservation_id), its(:capacity_reservation_specification), its(:hibernation_options), its(:licenses), its(:metadata_options)
|
1121
|
+
### its(:ami_launch_index), its(:image_id), its(:instance_id), its(:instance_type), its(:kernel_id), its(:key_name), its(:launch_time), its(:monitoring), its(:placement), its(:platform), its(:private_dns_name), its(:private_ip_address), its(:product_codes), its(:public_dns_name), its(:public_ip_address), its(:ramdisk_id), its(:state_transition_reason), its(:subnet_id), its(:vpc_id), its(:architecture), its(:client_token), its(:ebs_optimized), its(:ena_support), its(:hypervisor), its(:instance_lifecycle), its(:elastic_gpu_associations), its(:elastic_inference_accelerator_associations), its(:outpost_arn), its(:root_device_name), its(:root_device_type), its(:source_dest_check), its(:spot_instance_request_id), its(:sriov_net_support), its(:state_reason), its(:virtualization_type), its(:cpu_options), its(:capacity_reservation_id), its(:capacity_reservation_specification), its(:hibernation_options), its(:licenses), its(:metadata_options), its(:enclave_options), its(:boot_mode)
|
1120
1122
|
### :unlock: Advanced use
|
1121
1123
|
|
1122
1124
|
`ec2` can use `Aws::EC2::Instance` resource (see http://docs.aws.amazon.com/sdkforruby/api/Aws/EC2/Instance.html).
|
@@ -1212,7 +1214,7 @@ describe ecs_cluster('my-ecs-cluster') do
|
|
1212
1214
|
end
|
1213
1215
|
```
|
1214
1216
|
|
1215
|
-
### its(:cluster_arn), its(:cluster_name), its(:status), its(:registered_container_instances_count), its(:running_tasks_count), its(:pending_tasks_count), its(:active_services_count), its(:statistics), its(:tags), its(:settings), its(:capacity_providers), its(:default_capacity_provider_strategy), its(:attachments), its(:attachments_status)
|
1217
|
+
### its(:cluster_arn), its(:cluster_name), its(:configuration), its(:status), its(:registered_container_instances_count), its(:running_tasks_count), its(:pending_tasks_count), its(:active_services_count), its(:statistics), its(:tags), its(:settings), its(:capacity_providers), its(:default_capacity_provider_strategy), its(:attachments), its(:attachments_status)
|
1216
1218
|
## <a name="ecs_container_instance">ecs_container_instance</a>
|
1217
1219
|
|
1218
1220
|
ECS Container Instance resource type.
|
@@ -1259,7 +1261,7 @@ describe ecs_service('my-ecs-service') do
|
|
1259
1261
|
end
|
1260
1262
|
```
|
1261
1263
|
|
1262
|
-
### its(:service_arn), its(:service_name), its(:cluster_arn), its(:load_balancers), its(:service_registries), its(:status), its(:desired_count), its(:running_count), its(:pending_count), its(:launch_type), its(:capacity_provider_strategy), its(:platform_version), its(:task_definition), its(:task_sets), its(:role_arn), its(:created_at), its(:placement_constraints), its(:placement_strategy), its(:network_configuration), its(:health_check_grace_period_seconds), its(:scheduling_strategy), its(:deployment_controller), its(:tags), its(:created_by), its(:enable_ecs_managed_tags), its(:propagate_tags)
|
1264
|
+
### its(:service_arn), its(:service_name), its(:cluster_arn), its(:load_balancers), its(:service_registries), its(:status), its(:desired_count), its(:running_count), its(:pending_count), its(:launch_type), its(:capacity_provider_strategy), its(:platform_version), its(:task_definition), its(:task_sets), its(:role_arn), its(:created_at), its(:placement_constraints), its(:placement_strategy), its(:network_configuration), its(:health_check_grace_period_seconds), its(:scheduling_strategy), its(:deployment_controller), its(:tags), its(:created_by), its(:enable_ecs_managed_tags), its(:propagate_tags), its(:enable_execute_command)
|
1263
1265
|
## <a name="ecs_task_definition">ecs_task_definition</a>
|
1264
1266
|
|
1265
1267
|
ECS Task Definition resource type.
|
@@ -1281,7 +1283,7 @@ describe ecs_task_definition('my-ecs-task-definition') do
|
|
1281
1283
|
end
|
1282
1284
|
```
|
1283
1285
|
|
1284
|
-
### its(:task_definition_arn), its(:family), its(:task_role_arn), its(:execution_role_arn), its(:network_mode), its(:revision), its(:volumes), its(:status), its(:requires_attributes), its(:placement_constraints), its(:compatibilities), its(:requires_compatibilities), its(:cpu), its(:memory), its(:inference_accelerators), its(:pid_mode), its(:ipc_mode), its(:proxy_configuration)
|
1286
|
+
### its(:task_definition_arn), its(:family), its(:task_role_arn), its(:execution_role_arn), its(:network_mode), its(:revision), its(:volumes), its(:status), its(:requires_attributes), its(:placement_constraints), its(:compatibilities), its(:requires_compatibilities), its(:cpu), its(:memory), its(:inference_accelerators), its(:pid_mode), its(:ipc_mode), its(:proxy_configuration), its(:registered_at), its(:deregistered_at), its(:registered_by), its(:ephemeral_storage)
|
1285
1287
|
## <a name="efs">efs</a>
|
1286
1288
|
|
1287
1289
|
EFS resource type.
|
@@ -1303,7 +1305,7 @@ describe efs('my-efs') do
|
|
1303
1305
|
end
|
1304
1306
|
```
|
1305
1307
|
|
1306
|
-
### its(:owner_id), its(:creation_token), its(:file_system_id), its(:file_system_arn), its(:creation_time), its(:life_cycle_state), its(:name), its(:number_of_mount_targets), its(:performance_mode), its(:encrypted), its(:kms_key_id), its(:throughput_mode), its(:provisioned_throughput_in_mibps)
|
1308
|
+
### its(:owner_id), its(:creation_token), its(:file_system_id), its(:file_system_arn), its(:creation_time), its(:life_cycle_state), its(:name), its(:number_of_mount_targets), its(:performance_mode), its(:encrypted), its(:kms_key_id), its(:throughput_mode), its(:provisioned_throughput_in_mibps), its(:availability_zone_name), its(:availability_zone_id)
|
1307
1309
|
## <a name="elastic_ip">elastic_ip</a>
|
1308
1310
|
|
1309
1311
|
Elastic IP resource type.
|
@@ -1355,7 +1357,22 @@ describe eks('my-eks') do
|
|
1355
1357
|
end
|
1356
1358
|
```
|
1357
1359
|
|
1358
|
-
### its(:name), its(:arn), its(:created_at), its(:version), its(:endpoint), its(:role_arn), its(:logging), its(:identity), its(:status), its(:client_request_token), its(:platform_version), its(:tags), its(:encryption_config)
|
1360
|
+
### its(:name), its(:arn), its(:created_at), its(:version), its(:endpoint), its(:role_arn), its(:kubernetes_network_config), its(:logging), its(:identity), its(:status), its(:client_request_token), its(:platform_version), its(:tags), its(:encryption_config)
|
1361
|
+
## <a name="eks_nodegroup">eks_nodegroup</a>
|
1362
|
+
|
1363
|
+
EksNodegroup resource type.
|
1364
|
+
|
1365
|
+
### exist
|
1366
|
+
|
1367
|
+
```ruby
|
1368
|
+
describe eks_nodegroup('my-eks-nodegroup'), cluster: 'my-cluster' do
|
1369
|
+
it { should exist }
|
1370
|
+
end
|
1371
|
+
```
|
1372
|
+
|
1373
|
+
### be_active, be_inactive
|
1374
|
+
|
1375
|
+
### its(:nodegroup_name), its(:nodegroup_arn), its(:cluster_name), its(:version), its(:release_version), its(:created_at), its(:modified_at), its(:status), its(:capacity_type), its(:scaling_config), its(:instance_types), its(:subnets), its(:remote_access), its(:ami_type), its(:node_role), its(:labels), its(:resources), its(:disk_size), its(:health), its(:launch_template), its(:tags)
|
1359
1376
|
## <a name="elasticache">elasticache</a>
|
1360
1377
|
|
1361
1378
|
Elasticache resource type.
|
@@ -1424,7 +1441,7 @@ describe elasticache('my-rep-group-001') do
|
|
1424
1441
|
end
|
1425
1442
|
```
|
1426
1443
|
|
1427
|
-
### its(:cache_cluster_id), its(:configuration_endpoint), its(:client_download_landing_page), its(:cache_node_type), its(:engine), its(:engine_version), its(:cache_cluster_status), its(:num_cache_nodes), its(:preferred_availability_zone), its(:cache_cluster_create_time), its(:preferred_maintenance_window), its(:notification_configuration), its(:cache_security_groups), its(:cache_subnet_group_name), its(:cache_nodes), its(:auto_minor_version_upgrade), its(:replication_group_id), its(:snapshot_retention_limit), its(:snapshot_window), its(:auth_token_enabled), its(:auth_token_last_modified_date), its(:transit_encryption_enabled), its(:at_rest_encryption_enabled), its(:arn)
|
1444
|
+
### its(:cache_cluster_id), its(:configuration_endpoint), its(:client_download_landing_page), its(:cache_node_type), its(:engine), its(:engine_version), its(:cache_cluster_status), its(:num_cache_nodes), its(:preferred_availability_zone), its(:preferred_outpost_arn), its(:cache_cluster_create_time), its(:preferred_maintenance_window), its(:notification_configuration), its(:cache_security_groups), its(:cache_subnet_group_name), its(:cache_nodes), its(:auto_minor_version_upgrade), its(:replication_group_id), its(:snapshot_retention_limit), its(:snapshot_window), its(:auth_token_enabled), its(:auth_token_last_modified_date), its(:transit_encryption_enabled), its(:at_rest_encryption_enabled), its(:arn), its(:replication_group_log_delivery_enabled), its(:log_delivery_configurations)
|
1428
1445
|
## <a name="elasticache_cache_parameter_group">elasticache_cache_parameter_group</a>
|
1429
1446
|
|
1430
1447
|
ElasticacheCacheParameterGroup resource type.
|
@@ -1503,7 +1520,7 @@ end
|
|
1503
1520
|
```
|
1504
1521
|
|
1505
1522
|
|
1506
|
-
### its(:domain_id), its(:domain_name), its(:arn), its(:created), its(:deleted), its(:endpoint), its(:endpoints), its(:processing), its(:upgrade_processing), its(:elasticsearch_version), its(:access_policies), its(:snapshot_options), its(:vpc_options), its(:cognito_options), its(:encryption_at_rest_options), its(:node_to_node_encryption_options), its(:advanced_options), its(:log_publishing_options), its(:service_software_options), its(:domain_endpoint_options), its(:advanced_security_options)
|
1523
|
+
### its(:domain_id), its(:domain_name), its(:arn), its(:created), its(:deleted), its(:endpoint), its(:endpoints), its(:processing), its(:upgrade_processing), its(:elasticsearch_version), its(:access_policies), its(:snapshot_options), its(:vpc_options), its(:cognito_options), its(:encryption_at_rest_options), its(:node_to_node_encryption_options), its(:advanced_options), its(:log_publishing_options), its(:service_software_options), its(:domain_endpoint_options), its(:advanced_security_options), its(:auto_tune_options)
|
1507
1524
|
## <a name="elastictranscoder_pipeline">elastictranscoder_pipeline</a>
|
1508
1525
|
|
1509
1526
|
ElastictranscoderPipeline resource type.
|
@@ -1648,7 +1665,7 @@ describe emr('my-emr') do
|
|
1648
1665
|
end
|
1649
1666
|
```
|
1650
1667
|
|
1651
|
-
### its(:id), its(:name), its(:instance_collection_type), its(:log_uri), its(:log_encryption_kms_key_id), its(:requested_ami_version), its(:running_ami_version), its(:release_label), its(:auto_terminate), its(:termination_protected), its(:visible_to_all_users), its(:service_role), its(:normalized_instance_hours), its(:master_public_dns_name), its(:configurations), its(:security_configuration), its(:auto_scaling_role), its(:scale_down_behavior), its(:custom_ami_id), its(:ebs_root_volume_size), its(:repo_upgrade_on_boot), its(:cluster_arn), its(:outpost_arn), its(:step_concurrency_level)
|
1668
|
+
### its(:id), its(:name), its(:instance_collection_type), its(:log_uri), its(:log_encryption_kms_key_id), its(:requested_ami_version), its(:running_ami_version), its(:release_label), its(:auto_terminate), its(:termination_protected), its(:visible_to_all_users), its(:service_role), its(:normalized_instance_hours), its(:master_public_dns_name), its(:configurations), its(:security_configuration), its(:auto_scaling_role), its(:scale_down_behavior), its(:custom_ami_id), its(:ebs_root_volume_size), its(:repo_upgrade_on_boot), its(:cluster_arn), its(:outpost_arn), its(:step_concurrency_level), its(:placement_groups)
|
1652
1669
|
## <a name="firehose">firehose</a>
|
1653
1670
|
|
1654
1671
|
Firehose resource type.
|
@@ -1846,7 +1863,7 @@ describe iam_policy('my-iam-user') do
|
|
1846
1863
|
end
|
1847
1864
|
```
|
1848
1865
|
|
1849
|
-
### its(:policy_name), its(:policy_id), its(:arn), its(:path), its(:default_version_id), its(:attachment_count), its(:permissions_boundary_usage_count), its(:is_attachable), its(:description), its(:create_date), its(:update_date)
|
1866
|
+
### its(:policy_name), its(:policy_id), its(:arn), its(:path), its(:default_version_id), its(:attachment_count), its(:permissions_boundary_usage_count), its(:is_attachable), its(:description), its(:create_date), its(:update_date), its(:tags)
|
1850
1867
|
## <a name="iam_role">iam_role</a>
|
1851
1868
|
|
1852
1869
|
IamRole resource type.
|
@@ -2210,7 +2227,7 @@ end
|
|
2210
2227
|
|
2211
2228
|
This matcher does not support Amazon S3 event sources ([see SDK doc](http://docs.aws.amazon.com/sdkforruby/api/Aws/Lambda/Client.html#list_event_source_mappings-instance_method)).
|
2212
2229
|
|
2213
|
-
### its(:function_name), its(:function_arn), its(:runtime), its(:role), its(:handler), its(:code_size), its(:description), its(:timeout), its(:memory_size), its(:last_modified), its(:code_sha_256), its(:version), its(:vpc_config), its(:dead_letter_config), its(:kms_key_arn), its(:master_arn), its(:revision_id), its(:layers), its(:state), its(:state_reason), its(:state_reason_code), its(:last_update_status), its(:last_update_status_reason), its(:last_update_status_reason_code), its(:file_system_configs)
|
2230
|
+
### its(:function_name), its(:function_arn), its(:runtime), its(:role), its(:handler), its(:code_size), its(:description), its(:timeout), its(:memory_size), its(:last_modified), its(:code_sha_256), its(:version), its(:vpc_config), its(:dead_letter_config), its(:kms_key_arn), its(:master_arn), its(:revision_id), its(:layers), its(:state), its(:state_reason), its(:state_reason_code), its(:last_update_status), its(:last_update_status_reason), its(:last_update_status_reason_code), its(:file_system_configs), its(:package_type), its(:image_config_response), its(:signing_profile_version_arn), its(:signing_job_arn)
|
2214
2231
|
## <a name="launch_configuration">launch_configuration</a>
|
2215
2232
|
|
2216
2233
|
LaunchConfiguration resource type.
|
@@ -2356,7 +2373,7 @@ end
|
|
2356
2373
|
|
2357
2374
|
### be_updating
|
2358
2375
|
|
2359
|
-
### its(:active_operation_arn), its(:client_authentication), its(:cluster_arn), its(:cluster_name), its(:creation_time), its(:current_version), its(:enhanced_monitoring), its(:number_of_broker_nodes), its(:state), its(:zookeeper_connect_string)
|
2376
|
+
### its(:active_operation_arn), its(:client_authentication), its(:cluster_arn), its(:cluster_name), its(:creation_time), its(:current_version), its(:enhanced_monitoring), its(:number_of_broker_nodes), its(:state), its(:zookeeper_connect_string), its(:zookeeper_connect_string_tls)
|
2360
2377
|
## <a name="nat_gateway">nat_gateway</a>
|
2361
2378
|
|
2362
2379
|
NatGateway resource type.
|
@@ -2607,7 +2624,7 @@ describe nlb('my-nlb') do
|
|
2607
2624
|
end
|
2608
2625
|
```
|
2609
2626
|
|
2610
|
-
### its(:load_balancer_arn), its(:dns_name), its(:canonical_hosted_zone_id), its(:created_time), its(:load_balancer_name), its(:scheme), its(:vpc_id), its(:type), its(:security_groups), its(:ip_address_type)
|
2627
|
+
### its(:load_balancer_arn), its(:dns_name), its(:canonical_hosted_zone_id), its(:created_time), its(:load_balancer_name), its(:scheme), its(:vpc_id), its(:type), its(:security_groups), its(:ip_address_type), its(:customer_owned_ipv_4_pool)
|
2611
2628
|
## <a name="nlb_listener">nlb_listener</a>
|
2612
2629
|
|
2613
2630
|
NlbListener resource type.
|
@@ -2687,7 +2704,7 @@ end
|
|
2687
2704
|
```
|
2688
2705
|
|
2689
2706
|
|
2690
|
-
### its(:target_group_arn), its(:target_group_name), its(:protocol), its(:port), its(:vpc_id), its(:health_check_protocol), its(:health_check_port), its(:health_check_enabled), its(:health_check_interval_seconds), its(:health_check_timeout_seconds), its(:healthy_threshold_count), its(:unhealthy_threshold_count), its(:health_check_path), its(:load_balancer_arns), its(:target_type)
|
2707
|
+
### its(:target_group_arn), its(:target_group_name), its(:protocol), its(:port), its(:vpc_id), its(:health_check_protocol), its(:health_check_port), its(:health_check_enabled), its(:health_check_interval_seconds), its(:health_check_timeout_seconds), its(:healthy_threshold_count), its(:unhealthy_threshold_count), its(:health_check_path), its(:load_balancer_arns), its(:target_type), its(:protocol_version)
|
2691
2708
|
## <a name="rds">rds</a>
|
2692
2709
|
|
2693
2710
|
RDS resource type.
|
@@ -2784,7 +2801,7 @@ end
|
|
2784
2801
|
```
|
2785
2802
|
|
2786
2803
|
|
2787
|
-
### its(:vpc_id), its(:db_instance_identifier), its(:db_instance_class), its(:engine), its(:db_instance_status), its(:master_username), its(:db_name), its(:endpoint), its(:allocated_storage), its(:instance_create_time), its(:preferred_backup_window), its(:backup_retention_period), its(:db_security_groups), its(:availability_zone), its(:preferred_maintenance_window), its(:pending_modified_values), its(:latest_restorable_time), its(:multi_az), its(:engine_version), its(:auto_minor_version_upgrade), its(:read_replica_source_db_instance_identifier), its(:read_replica_db_instance_identifiers), its(:read_replica_db_cluster_identifiers), its(:license_model), its(:iops), its(:character_set_name), its(:secondary_availability_zone), its(:publicly_accessible), its(:status_infos), its(:storage_type), its(:tde_credential_arn), its(:db_instance_port), its(:db_cluster_identifier), its(:storage_encrypted), its(:kms_key_id), its(:dbi_resource_id), its(:ca_certificate_identifier), its(:domain_memberships), its(:copy_tags_to_snapshot), its(:monitoring_interval), its(:enhanced_monitoring_resource_arn), its(:monitoring_role_arn), its(:promotion_tier), its(:db_instance_arn), its(:timezone), its(:iam_database_authentication_enabled), its(:performance_insights_enabled), its(:performance_insights_kms_key_id), its(:performance_insights_retention_period), its(:enabled_cloudwatch_logs_exports), its(:processor_features), its(:deletion_protection), its(:associated_roles), its(:listener_endpoint), its(:max_allocated_storage)
|
2804
|
+
### its(:vpc_id), its(:db_instance_identifier), its(:db_instance_class), its(:engine), its(:db_instance_status), its(:master_username), its(:db_name), its(:endpoint), its(:allocated_storage), its(:instance_create_time), its(:preferred_backup_window), its(:backup_retention_period), its(:db_security_groups), its(:availability_zone), its(:preferred_maintenance_window), its(:pending_modified_values), its(:latest_restorable_time), its(:multi_az), its(:engine_version), its(:auto_minor_version_upgrade), its(:read_replica_source_db_instance_identifier), its(:read_replica_db_instance_identifiers), its(:read_replica_db_cluster_identifiers), its(:replica_mode), its(:license_model), its(:iops), its(:character_set_name), its(:nchar_character_set_name), its(:secondary_availability_zone), its(:publicly_accessible), its(:status_infos), its(:storage_type), its(:tde_credential_arn), its(:db_instance_port), its(:db_cluster_identifier), its(:storage_encrypted), its(:kms_key_id), its(:dbi_resource_id), its(:ca_certificate_identifier), its(:domain_memberships), its(:copy_tags_to_snapshot), its(:monitoring_interval), its(:enhanced_monitoring_resource_arn), its(:monitoring_role_arn), its(:promotion_tier), its(:db_instance_arn), its(:timezone), its(:iam_database_authentication_enabled), its(:performance_insights_enabled), its(:performance_insights_kms_key_id), its(:performance_insights_retention_period), its(:enabled_cloudwatch_logs_exports), its(:processor_features), its(:deletion_protection), its(:associated_roles), its(:listener_endpoint), its(:max_allocated_storage), its(:tag_list), its(:db_instance_automated_backups_replications), its(:customer_owned_ip_enabled), its(:aws_backup_recovery_point_arn)
|
2788
2805
|
### :unlock: Advanced use
|
2789
2806
|
|
2790
2807
|
`rds` can use `Aws::RDS::DBInstance` resource (see http://docs.aws.amazon.com/sdkforruby/api/Aws/RDS/DBInstance.html).
|
@@ -2916,7 +2933,7 @@ describe redshift('my-redshift') do
|
|
2916
2933
|
end
|
2917
2934
|
```
|
2918
2935
|
|
2919
|
-
### its(:vpc_id), its(:cluster_identifier), its(:node_type), its(:cluster_status), its(:cluster_availability_status), its(:modify_status), its(:master_username), its(:db_name), its(:endpoint), its(:cluster_create_time), its(:automated_snapshot_retention_period), its(:manual_snapshot_retention_period), its(:cluster_security_groups), its(:cluster_subnet_group_name), its(:vpc_id), its(:availability_zone), its(:preferred_maintenance_window), its(:pending_modified_values), its(:cluster_version), its(:allow_version_upgrade), its(:number_of_nodes), its(:publicly_accessible), its(:encrypted), its(:restore_status), its(:data_transfer_progress), its(:hsm_status), its(:cluster_snapshot_copy_status), its(:cluster_public_key), its(:cluster_nodes), its(:elastic_ip_status), its(:cluster_revision_number), its(:kms_key_id), its(:enhanced_vpc_routing), its(:iam_roles), its(:pending_actions), its(:maintenance_track_name), its(:elastic_resize_number_of_node_options), its(:deferred_maintenance_windows), its(:snapshot_schedule_identifier), its(:snapshot_schedule_state), its(:expected_next_snapshot_schedule_time), its(:expected_next_snapshot_schedule_time_status), its(:next_maintenance_window_start_time), its(:resize_info)
|
2936
|
+
### its(:vpc_id), its(:cluster_identifier), its(:node_type), its(:cluster_status), its(:cluster_availability_status), its(:modify_status), its(:master_username), its(:db_name), its(:endpoint), its(:cluster_create_time), its(:automated_snapshot_retention_period), its(:manual_snapshot_retention_period), its(:cluster_security_groups), its(:cluster_subnet_group_name), its(:vpc_id), its(:availability_zone), its(:preferred_maintenance_window), its(:pending_modified_values), its(:cluster_version), its(:allow_version_upgrade), its(:number_of_nodes), its(:publicly_accessible), its(:encrypted), its(:restore_status), its(:data_transfer_progress), its(:hsm_status), its(:cluster_snapshot_copy_status), its(:cluster_public_key), its(:cluster_nodes), its(:elastic_ip_status), its(:cluster_revision_number), its(:kms_key_id), its(:enhanced_vpc_routing), its(:iam_roles), its(:pending_actions), its(:maintenance_track_name), its(:elastic_resize_number_of_node_options), its(:deferred_maintenance_windows), its(:snapshot_schedule_identifier), its(:snapshot_schedule_state), its(:expected_next_snapshot_schedule_time), its(:expected_next_snapshot_schedule_time_status), its(:next_maintenance_window_start_time), its(:resize_info), its(:availability_zone_relocation_status), its(:cluster_namespace_arn), its(:total_storage_capacity_in_mega_bytes), its(:aqua_configuration)
|
2920
2937
|
## <a name="redshift_cluster_parameter_group">redshift_cluster_parameter_group</a>
|
2921
2938
|
|
2922
2939
|
RedshiftClusterParameterGroup resource type.
|
@@ -3113,6 +3130,15 @@ end
|
|
3113
3130
|
```
|
3114
3131
|
|
3115
3132
|
|
3133
|
+
### have_location
|
3134
|
+
|
3135
|
+
```ruby
|
3136
|
+
describe s3_bucket('my-bucket') do
|
3137
|
+
it { should have_location('us-east-1') }
|
3138
|
+
end
|
3139
|
+
```
|
3140
|
+
|
3141
|
+
|
3116
3142
|
### have_logging_enabled
|
3117
3143
|
|
3118
3144
|
```ruby
|
@@ -3232,7 +3258,7 @@ describe secretsmanager('my-secret') do
|
|
3232
3258
|
end
|
3233
3259
|
```
|
3234
3260
|
|
3235
|
-
### its(:arn), its(:name), its(:description), its(:kms_key_id), its(:rotation_enabled), its(:rotation_lambda_arn), its(:last_rotated_date), its(:last_changed_date), its(:last_accessed_date), its(:deleted_date), its(:owning_service), its(:created_date)
|
3261
|
+
### its(:arn), its(:name), its(:description), its(:kms_key_id), its(:rotation_enabled), its(:rotation_lambda_arn), its(:last_rotated_date), its(:last_changed_date), its(:last_accessed_date), its(:deleted_date), its(:owning_service), its(:created_date), its(:primary_region), its(:replication_status)
|
3236
3262
|
## <a name="security_group">security_group</a>
|
3237
3263
|
|
3238
3264
|
SecurityGroup resource type.
|
@@ -3644,6 +3670,86 @@ describe vpc('my-vpc') do
|
|
3644
3670
|
end
|
3645
3671
|
```
|
3646
3672
|
|
3673
|
+
## <a name="vpc_endpoints">vpc_endpoints</a>
|
3674
|
+
|
3675
|
+
VpcEndpoints resource type.
|
3676
|
+
|
3677
|
+
### exist
|
3678
|
+
|
3679
|
+
```ruby
|
3680
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
3681
|
+
it { should exist }
|
3682
|
+
end
|
3683
|
+
```
|
3684
|
+
|
3685
|
+
describe vpc_endpoints('vpce-05907f23265b25f20'), region: $tfvars["region"]["value"] do
|
3686
|
+
it { should exist }
|
3687
|
+
it { should be_available }
|
3688
|
+
it { should have_subnet('subnet-040e19eabf3226f99') }
|
3689
|
+
it { should belong_to_vpc('vpc-00af9dcc0134b48e0') }
|
3690
|
+
its(:private_dns_enabled) { should eq true }
|
3691
|
+
its(:vpc_endpoint_type) { should eq 'Interface' }
|
3692
|
+
its(:service_name) { should eq 'com.amazonaws.eu-west-1.codebuild' }
|
3693
|
+
end
|
3694
|
+
|
3695
|
+
|
3696
|
+
### be_available
|
3697
|
+
|
3698
|
+
### be_deleted
|
3699
|
+
|
3700
|
+
### be_deleting
|
3701
|
+
|
3702
|
+
### be_expired
|
3703
|
+
|
3704
|
+
### be_failed
|
3705
|
+
|
3706
|
+
### be_pending
|
3707
|
+
|
3708
|
+
### be_pendingacceptance
|
3709
|
+
|
3710
|
+
### be_rejected
|
3711
|
+
|
3712
|
+
### have_route_table
|
3713
|
+
|
3714
|
+
```ruby
|
3715
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
3716
|
+
it { should have_route_table('rtb-abc123') }
|
3717
|
+
end
|
3718
|
+
```
|
3719
|
+
|
3720
|
+
|
3721
|
+
### have_subnet
|
3722
|
+
|
3723
|
+
```ruby
|
3724
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
3725
|
+
it { should have_subnet('subnet-abc123') }
|
3726
|
+
end
|
3727
|
+
```
|
3728
|
+
|
3729
|
+
|
3730
|
+
### have_tag
|
3731
|
+
|
3732
|
+
```ruby
|
3733
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
3734
|
+
it { should have_tag('env').value('dev') }
|
3735
|
+
end
|
3736
|
+
```
|
3737
|
+
|
3738
|
+
|
3739
|
+
|
3740
|
+
### :unlock: Advanced use
|
3741
|
+
|
3742
|
+
`vpc_endpoints` can use `Aws::EC2::Types::VpcEndpoint` resource (see https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/EC2/Types/VpcEndpoint.html).
|
3743
|
+
|
3744
|
+
```ruby
|
3745
|
+
describe vpc_endpoints('my-vpc-endpoint') do
|
3746
|
+
its(:private_dns_enabled) { should eq true }
|
3747
|
+
its(:vpc_endpoint_type) { should eq 'Interface' }
|
3748
|
+
its(:service_name) { should eq 'com.amazonaws.eu-west-1.codebuild' }
|
3749
|
+
end
|
3750
|
+
```
|
3751
|
+
|
3752
|
+
|
3647
3753
|
## <a name="vpn_connection">vpn_connection</a>
|
3648
3754
|
|
3649
3755
|
VpnConnection resource type.
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module Awspec::Generator
|
2
|
+
module Doc
|
3
|
+
module Type
|
4
|
+
class EksNodegroup < Base
|
5
|
+
def initialize
|
6
|
+
super
|
7
|
+
@type_name = 'EksNodegroup'
|
8
|
+
@type = Awspec::Type::EksNodegroup.new('my-eks-nodegroup')
|
9
|
+
@ret = @type.resource_via_client
|
10
|
+
@matchers = [
|
11
|
+
Awspec::Type::EksNodegroup::STATES.map { |state| 'be_' + state.downcase }.join(', ')
|
12
|
+
]
|
13
|
+
@ignore_matchers = Awspec::Type::EksNodegroup::STATES.map { |state| 'be_' + state.downcase }
|
14
|
+
@describes = []
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
module Awspec::Generator
|
2
|
+
module Doc
|
3
|
+
module Type
|
4
|
+
class VpcEndpoints < Base
|
5
|
+
def initialize
|
6
|
+
super
|
7
|
+
@type_name = 'VpcEndpoints'
|
8
|
+
@type = Awspec::Type::VpcEndpoints.new('my-vpc-endpoint')
|
9
|
+
@ret = @type.resource_via_client
|
10
|
+
@matchers = []
|
11
|
+
@ignore_matchers = []
|
12
|
+
@describes = []
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -11,7 +11,7 @@ module Awspec::Generator
|
|
11
11
|
group_name: group.group_name,
|
12
12
|
policy_name: policy_name
|
13
13
|
})
|
14
|
-
document = JSON.generate(JSON.parse(URI.
|
14
|
+
document = JSON.generate(JSON.parse(URI.decode_www_form_component(res.policy_document)))
|
15
15
|
"it { should have_inline_policy('#{policy_name}').policy_document('#{document}') }"
|
16
16
|
end
|
17
17
|
content = ERB.new(iam_group_spec_template, nil, '-').result(binding).gsub(/^\n/, '')
|
@@ -11,7 +11,7 @@ module Awspec::Generator
|
|
11
11
|
role_name: role.role_name,
|
12
12
|
policy_name: policy_name
|
13
13
|
})
|
14
|
-
document = JSON.generate(JSON.parse(URI.
|
14
|
+
document = JSON.generate(JSON.parse(URI.decode_www_form_component(res.policy_document)))
|
15
15
|
"it { should have_inline_policy('#{policy_name}').policy_document('#{document}') }"
|
16
16
|
end
|
17
17
|
content = ERB.new(iam_role_spec_template, nil, '-').result(binding).gsub(/^\n/, '')
|
@@ -11,7 +11,7 @@ module Awspec::Generator
|
|
11
11
|
user_name: user.user_name,
|
12
12
|
policy_name: policy_name
|
13
13
|
})
|
14
|
-
document = JSON.generate(JSON.parse(URI.
|
14
|
+
document = JSON.generate(JSON.parse(URI.decode_www_form_component(res.policy_document)))
|
15
15
|
"it { should have_inline_policy('#{policy_name}').policy_document('#{document}') }"
|
16
16
|
end
|
17
17
|
content = ERB.new(iam_user_spec_template, nil, '-').result(binding).gsub(/^\n/, '')
|
@@ -102,6 +102,9 @@ describe s3_bucket('<%= bucket.name %>') do
|
|
102
102
|
<%= line %>
|
103
103
|
<% end %>
|
104
104
|
<%- end -%>
|
105
|
+
<%- if location -%>
|
106
|
+
it { should have_location('<%= location %>') }
|
107
|
+
<%- end -%>
|
105
108
|
end
|
106
109
|
EOF
|
107
110
|
template
|
@@ -117,6 +120,7 @@ EOF
|
|
117
120
|
bucket_policy = policy.policy.read if policy
|
118
121
|
lifecycle_rule = find_bucket_lifecycle_configuration(bucket.name)
|
119
122
|
lifecycle_specs = generate_lifecycle_rule_specs(lifecycle_rule) if lifecycle_rule
|
123
|
+
location = find_bucket_location(bucket.name)
|
120
124
|
ERB.new(bucket_spec_template, nil, '-').result(binding).gsub(/^\n/, '')
|
121
125
|
end
|
122
126
|
end
|
data/lib/awspec/helper/finder.rb
CHANGED
@@ -2,6 +2,7 @@ require 'aws-sdk'
|
|
2
2
|
require 'awspec/helper/finder/nlb'
|
3
3
|
require 'awspec/helper/finder/alb'
|
4
4
|
require 'awspec/helper/finder/vpc'
|
5
|
+
require 'awspec/helper/finder/vpc_endpoints'
|
5
6
|
require 'awspec/helper/finder/subnet'
|
6
7
|
require 'awspec/helper/finder/ec2'
|
7
8
|
require 'awspec/helper/finder/ecr'
|
@@ -60,6 +61,7 @@ module Awspec::Helper
|
|
60
61
|
include Awspec::Helper::Finder::Nlb
|
61
62
|
include Awspec::Helper::Finder::Alb
|
62
63
|
include Awspec::Helper::Finder::Vpc
|
64
|
+
include Awspec::Helper::Finder::VpcEndpoints
|
63
65
|
include Awspec::Helper::Finder::Subnet
|
64
66
|
include Awspec::Helper::Finder::Ec2
|
65
67
|
include Awspec::Helper::Finder::Ecr
|
@@ -160,7 +162,8 @@ module Awspec::Helper
|
|
160
162
|
}
|
161
163
|
|
162
164
|
CLIENT_OPTIONS = {
|
163
|
-
http_proxy: ENV['http_proxy'] || ENV['https_proxy'] || nil
|
165
|
+
http_proxy: ENV['http_proxy'] || ENV['https_proxy'] || nil,
|
166
|
+
http_wire_trace: ENV['http_wire_trace'] || false
|
164
167
|
}
|
165
168
|
|
166
169
|
CLIENTS.each do |method_name, client|
|
@@ -5,6 +5,11 @@ module Awspec::Helper
|
|
5
5
|
res = eks_client.describe_cluster({ name: name })
|
6
6
|
res.cluster
|
7
7
|
end
|
8
|
+
|
9
|
+
def find_eks_nodegroup(cluster_name, group_name)
|
10
|
+
res = eks_client.describe_nodegroup({ cluster_name: cluster_name, nodegroup_name: group_name })
|
11
|
+
res.nodegroup
|
12
|
+
end
|
8
13
|
end
|
9
14
|
end
|
10
15
|
end
|
@@ -35,6 +35,17 @@ module Awspec::Helper
|
|
35
35
|
nil
|
36
36
|
end
|
37
37
|
|
38
|
+
def find_bucket_location(id)
|
39
|
+
bucket_location = s3_client.get_bucket_location(bucket: id)
|
40
|
+
if bucket_location.location_constraint.nil? || bucket_location.location_constraint.empty?
|
41
|
+
'us-east-1'
|
42
|
+
else
|
43
|
+
bucket_location.location_constraint
|
44
|
+
end
|
45
|
+
rescue Aws::S3::Errors::ServiceError
|
46
|
+
nil
|
47
|
+
end
|
48
|
+
|
38
49
|
def find_bucket_logging(id)
|
39
50
|
s3_client.get_bucket_logging(bucket: id)
|
40
51
|
rescue Aws::S3::Errors::ServiceError
|
@@ -0,0 +1,15 @@
|
|
1
|
+
module Awspec::Helper
|
2
|
+
module Finder
|
3
|
+
module VpcEndpoints
|
4
|
+
def find_vpc_endpoint(id)
|
5
|
+
res = ec2_client.describe_vpc_endpoints({ vpc_endpoint_ids: [id] })
|
6
|
+
|
7
|
+
ret = res.vpc_endpoints.select do |vpce|
|
8
|
+
vpce.vpc_endpoint_id == id
|
9
|
+
end
|
10
|
+
|
11
|
+
ret.single_resource(id)
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
data/lib/awspec/helper/type.rb
CHANGED
@@ -12,7 +12,7 @@ module Awspec
|
|
12
12
|
batch_compute_environment batch_job_definition batch_job_queue cloudtrail
|
13
13
|
cloudwatch_alarm cloudwatch_event directconnect_virtual_interface
|
14
14
|
ebs ec2 ecr_repository ecs_cluster ecs_container_instance ecs_service ecs_task_definition
|
15
|
-
efs eks elasticache elasticache_cache_parameter_group elasticsearch elb emr firehose iam_group
|
15
|
+
efs eks eks_nodegroup elasticache elasticache_cache_parameter_group elasticsearch elb emr firehose iam_group
|
16
16
|
iam_policy iam_role iam_user kinesis kms lambda launch_configuration launch_template mq nat_gateway
|
17
17
|
network_acl network_interface nlb nlb_listener nlb_target_group
|
18
18
|
rds rds_db_cluster_parameter_group rds_db_parameter_group route53_hosted_zone
|
@@ -20,7 +20,7 @@ module Awspec
|
|
20
20
|
elastictranscoder_pipeline waf_web_acl wafregional_web_acl customer_gateway vpn_gateway vpn_connection
|
21
21
|
internet_gateway acm cloudwatch_logs dynamodb_table eip sqs ssm_parameter cloudformation_stack
|
22
22
|
codebuild sns_topic redshift redshift_cluster_parameter_group codedeploy codedeploy_deployment_group
|
23
|
-
secretsmanager msk transit_gateway cognito_identity_pool cognito_user_pool
|
23
|
+
secretsmanager msk transit_gateway cognito_identity_pool cognito_user_pool vpc_endpoints
|
24
24
|
)
|
25
25
|
|
26
26
|
ACCOUNT_ATTRIBUTES = %w(
|
@@ -0,0 +1,16 @@
|
|
1
|
+
Aws.config[:eks] = {
|
2
|
+
stub_responses: {
|
3
|
+
describe_nodegroup: {
|
4
|
+
nodegroup: {
|
5
|
+
version: '1.17',
|
6
|
+
release_version: '1.17.12-20210322',
|
7
|
+
cluster_name: 'my-cluster',
|
8
|
+
nodegroup_name: 'my-nodegroup',
|
9
|
+
nodegroup_arn: 'arn:aws:eks:us-west-2:012345678910:nodegroup/my-cluster/my-nodegroup/08bd000a',
|
10
|
+
created_at: Time.parse('2018-10-28 00:23:32 -0400'),
|
11
|
+
node_role: 'arn:aws:iam::012345678910:role/eks-nodegroup-role',
|
12
|
+
status: 'ACTIVE'
|
13
|
+
}
|
14
|
+
}
|
15
|
+
}
|
16
|
+
}
|
@@ -0,0 +1,64 @@
|
|
1
|
+
Aws.config[:ec2] = {
|
2
|
+
stub_responses: {
|
3
|
+
describe_vpc_endpoints: {
|
4
|
+
vpc_endpoints: [
|
5
|
+
{
|
6
|
+
vpc_endpoint_id: 'vpce-abc123',
|
7
|
+
vpc_endpoint_type: 'Gateway',
|
8
|
+
vpc_id: 'vpc-12345678',
|
9
|
+
service_name: 'com.amazonaws.us-east-1.s3',
|
10
|
+
state: 'available',
|
11
|
+
policy_document: '{"Version": "2008-10-17", "Statement": [{' \
|
12
|
+
'"Effect": "Allow", "Principal": "*", "Action": "*",' \
|
13
|
+
'"Resource": "*"}]}',
|
14
|
+
route_table_ids: ['rtb-0123456789abcdefg'],
|
15
|
+
subnet_ids: [],
|
16
|
+
groups: [],
|
17
|
+
private_dns_enabled: false,
|
18
|
+
requester_managed: false,
|
19
|
+
network_interface_ids: [],
|
20
|
+
dns_entries: [],
|
21
|
+
creation_timestamp: Time.new(2020, 8, 13, 9, 00, 00, '+00:00'),
|
22
|
+
tags: [
|
23
|
+
{
|
24
|
+
key: 'Name',
|
25
|
+
value: 'my_vpc_endpoint'
|
26
|
+
}
|
27
|
+
],
|
28
|
+
owner_id: '112233445566'
|
29
|
+
},
|
30
|
+
{
|
31
|
+
vpc_endpoint_id: 'vpce-abc124',
|
32
|
+
vpc_endpoint_type: 'Interface',
|
33
|
+
vpc_id: 'vpc-12345678',
|
34
|
+
service_name: 'com.amazonaws.eu-west-1.codebuild',
|
35
|
+
state: 'available',
|
36
|
+
policy_document: '{"Version": "2008-10-17", "Statement": [{' \
|
37
|
+
'"Effect": "Allow", "Principal": "*", "Action": "*",' \
|
38
|
+
'"Resource": "*"}]}',
|
39
|
+
route_table_ids: [],
|
40
|
+
subnet_ids: ['subnet-abc123'],
|
41
|
+
groups: [{ group_id: 'sg-abc123', group_name: 'default' }],
|
42
|
+
private_dns_enabled: true,
|
43
|
+
requester_managed: false,
|
44
|
+
network_interface_ids: ['eni-06f28a949cb88b84c'],
|
45
|
+
dns_entries: [
|
46
|
+
{
|
47
|
+
dns_name: 'vpce-05907f23265b25f20-wwafshom.codebuild.eu-west-1.vpce.amazonaws.com',
|
48
|
+
hosted_zone_id: 'Z38GZ743OKFT7T'
|
49
|
+
}
|
50
|
+
],
|
51
|
+
creation_timestamp: Time.new(2020, 8, 13, 9, 00, 00, '+00:00'),
|
52
|
+
tags: [
|
53
|
+
{
|
54
|
+
key: 'Name',
|
55
|
+
value: 'my_vpc_endpoint'
|
56
|
+
}
|
57
|
+
],
|
58
|
+
owner_id: '112233445566'
|
59
|
+
}
|
60
|
+
],
|
61
|
+
next_token: nil
|
62
|
+
}
|
63
|
+
}
|
64
|
+
}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
module Awspec::Type
|
2
|
+
class EksNodegroup < ResourceBase
|
3
|
+
attr_accessor :cluster
|
4
|
+
|
5
|
+
def initialize(group_name)
|
6
|
+
super
|
7
|
+
@group_name = group_name
|
8
|
+
end
|
9
|
+
|
10
|
+
def resource_via_client
|
11
|
+
@resource_via_client ||= find_eks_nodegroup(cluster, @group_name)
|
12
|
+
end
|
13
|
+
|
14
|
+
def id
|
15
|
+
@id ||= resource_via_client.nodegroup_arn if resource_via_client
|
16
|
+
end
|
17
|
+
|
18
|
+
def cluster
|
19
|
+
@cluster || 'default'
|
20
|
+
end
|
21
|
+
|
22
|
+
STATES = %w(ACTIVE INACTIVE)
|
23
|
+
|
24
|
+
STATES.each do |state|
|
25
|
+
define_method state.downcase + '?' do
|
26
|
+
resource_via_client.status == state
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
@@ -34,7 +34,7 @@ module Awspec::Type
|
|
34
34
|
group_name: id,
|
35
35
|
policy_name: policy_name
|
36
36
|
})
|
37
|
-
return JSON.parse(URI.
|
37
|
+
return JSON.parse(URI.decode_www_form_component(res.policy_document)) == JSON.parse(document) if document
|
38
38
|
res
|
39
39
|
end
|
40
40
|
|
data/lib/awspec/type/iam_role.rb
CHANGED
@@ -24,7 +24,7 @@ module Awspec::Type
|
|
24
24
|
role_name: resource_via_client.role_name,
|
25
25
|
policy_name: policy_name
|
26
26
|
})
|
27
|
-
return JSON.parse(URI.
|
27
|
+
return JSON.parse(URI.decode_www_form_component(res.policy_document)) == JSON.parse(document) if document
|
28
28
|
res
|
29
29
|
end
|
30
30
|
|
data/lib/awspec/type/iam_user.rb
CHANGED
@@ -24,7 +24,7 @@ module Awspec::Type
|
|
24
24
|
user_name: resource_via_client.user_name,
|
25
25
|
policy_name: policy_name
|
26
26
|
})
|
27
|
-
return JSON.parse(URI.
|
27
|
+
return JSON.parse(URI.decode_www_form_component(res.policy_document)) == JSON.parse(document) if document
|
28
28
|
res
|
29
29
|
end
|
30
30
|
|
data/lib/awspec/type/kms.rb
CHANGED
@@ -14,7 +14,7 @@ module Awspec::Type
|
|
14
14
|
|
15
15
|
def has_key_policy?(policy_name, document = nil)
|
16
16
|
res = kms_client.get_key_policy(key_id: id, policy_name: policy_name)
|
17
|
-
return JSON.parse(URI.
|
17
|
+
return JSON.parse(URI.decode_www_form_component(res.policy)) == JSON.parse(document) if document
|
18
18
|
res
|
19
19
|
end
|
20
20
|
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
module Awspec::Type
|
2
|
+
class VpcEndpoints < ResourceBase
|
3
|
+
aws_resource Aws::EC2::Types::VpcEndpoint
|
4
|
+
tags_allowed
|
5
|
+
|
6
|
+
def resource_via_client
|
7
|
+
@resource_via_client ||= find_vpc_endpoint(@display_name)
|
8
|
+
end
|
9
|
+
|
10
|
+
def id
|
11
|
+
@id ||= resource_via_client.vpc_endpoint_id if resource_via_client
|
12
|
+
end
|
13
|
+
|
14
|
+
STATES = %w(
|
15
|
+
pendingacceptance pending available deleting
|
16
|
+
deleted rejected failed expired
|
17
|
+
)
|
18
|
+
|
19
|
+
STATES.each do |state|
|
20
|
+
define_method state + '?' do
|
21
|
+
resource_via_client.state == state
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
def has_route_table?(route_table_id)
|
26
|
+
rts = resource_via_client.route_table_ids
|
27
|
+
|
28
|
+
ret = rts.find do |rt|
|
29
|
+
rt == route_table_id
|
30
|
+
end
|
31
|
+
return true if ret
|
32
|
+
end
|
33
|
+
|
34
|
+
def has_subnet?(subnet_id)
|
35
|
+
subnets = resource_via_client.subnet_ids
|
36
|
+
|
37
|
+
ret = subnets.find do |subnet|
|
38
|
+
subnet == subnet_id
|
39
|
+
end
|
40
|
+
return true if ret
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
data/lib/awspec/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: awspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.24.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- k1LoW
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-05-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk
|
@@ -266,6 +266,7 @@ files:
|
|
266
266
|
- doc/_resource_types/efs.md
|
267
267
|
- doc/_resource_types/eip.md
|
268
268
|
- doc/_resource_types/eks.md
|
269
|
+
- doc/_resource_types/eks_nodegroup.md
|
269
270
|
- doc/_resource_types/elasticache.md
|
270
271
|
- doc/_resource_types/elasticache_cache_parameter_group.md
|
271
272
|
- doc/_resource_types/elasticsearch.md
|
@@ -311,6 +312,7 @@ files:
|
|
311
312
|
- doc/_resource_types/subnet.md
|
312
313
|
- doc/_resource_types/transit_gateway.md
|
313
314
|
- doc/_resource_types/vpc.md
|
315
|
+
- doc/_resource_types/vpc_endpoints.md
|
314
316
|
- doc/_resource_types/vpn_connection.md
|
315
317
|
- doc/_resource_types/vpn_gateway.md
|
316
318
|
- doc/_resource_types/waf_web_acl.md
|
@@ -369,6 +371,7 @@ files:
|
|
369
371
|
- lib/awspec/generator/doc/type/efs.rb
|
370
372
|
- lib/awspec/generator/doc/type/eip.rb
|
371
373
|
- lib/awspec/generator/doc/type/eks.rb
|
374
|
+
- lib/awspec/generator/doc/type/eks_nodegroup.rb
|
372
375
|
- lib/awspec/generator/doc/type/elasticache.rb
|
373
376
|
- lib/awspec/generator/doc/type/elasticache_cache_parameter_group.rb
|
374
377
|
- lib/awspec/generator/doc/type/elasticsearch.rb
|
@@ -414,6 +417,7 @@ files:
|
|
414
417
|
- lib/awspec/generator/doc/type/subnet.rb
|
415
418
|
- lib/awspec/generator/doc/type/transit_gateway.rb
|
416
419
|
- lib/awspec/generator/doc/type/vpc.rb
|
420
|
+
- lib/awspec/generator/doc/type/vpc_endpoints.rb
|
417
421
|
- lib/awspec/generator/doc/type/vpn_connection.rb
|
418
422
|
- lib/awspec/generator/doc/type/vpn_gateway.rb
|
419
423
|
- lib/awspec/generator/doc/type/waf_web_acl.rb
|
@@ -511,6 +515,7 @@ files:
|
|
511
515
|
- lib/awspec/helper/finder/ssm_parameter.rb
|
512
516
|
- lib/awspec/helper/finder/subnet.rb
|
513
517
|
- lib/awspec/helper/finder/vpc.rb
|
518
|
+
- lib/awspec/helper/finder/vpc_endpoints.rb
|
514
519
|
- lib/awspec/helper/finder/waf.rb
|
515
520
|
- lib/awspec/helper/finder/wafregional.rb
|
516
521
|
- lib/awspec/helper/type.rb
|
@@ -597,6 +602,7 @@ files:
|
|
597
602
|
- lib/awspec/stub/efs.rb
|
598
603
|
- lib/awspec/stub/eip.rb
|
599
604
|
- lib/awspec/stub/eks.rb
|
605
|
+
- lib/awspec/stub/eks_nodegroup.rb
|
600
606
|
- lib/awspec/stub/elasticache.rb
|
601
607
|
- lib/awspec/stub/elasticache_cache_parameter_group.rb
|
602
608
|
- lib/awspec/stub/elasticsearch.rb
|
@@ -639,6 +645,7 @@ files:
|
|
639
645
|
- lib/awspec/stub/subnet.rb
|
640
646
|
- lib/awspec/stub/transit_gateway.rb
|
641
647
|
- lib/awspec/stub/vpc.rb
|
648
|
+
- lib/awspec/stub/vpc_endpoints.rb
|
642
649
|
- lib/awspec/stub/vpn_connection.rb
|
643
650
|
- lib/awspec/stub/vpn_gateway.rb
|
644
651
|
- lib/awspec/stub/waf_web_acl.rb
|
@@ -683,6 +690,7 @@ files:
|
|
683
690
|
- lib/awspec/type/efs.rb
|
684
691
|
- lib/awspec/type/eip.rb
|
685
692
|
- lib/awspec/type/eks.rb
|
693
|
+
- lib/awspec/type/eks_nodegroup.rb
|
686
694
|
- lib/awspec/type/elasticache.rb
|
687
695
|
- lib/awspec/type/elasticache_cache_parameter_group.rb
|
688
696
|
- lib/awspec/type/elasticsearch.rb
|
@@ -729,6 +737,7 @@ files:
|
|
729
737
|
- lib/awspec/type/subnet.rb
|
730
738
|
- lib/awspec/type/transit_gateway.rb
|
731
739
|
- lib/awspec/type/vpc.rb
|
740
|
+
- lib/awspec/type/vpc_endpoints.rb
|
732
741
|
- lib/awspec/type/vpn_connection.rb
|
733
742
|
- lib/awspec/type/vpn_gateway.rb
|
734
743
|
- lib/awspec/type/waf_web_acl.rb
|