title | platform |
---|---|
About the google_compute_region_instance_group_manager Resource |
gcp |
Use the google_compute_region_instance_group_manager
InSpec audit resource to test properties of a single multi-zone GCP compute instance group.
A google_compute_region_instance_group_manager
resource block declares the tests for a single GCP compute instance group by project, region and name.
describe google_compute_region_instance_group_manager(project: 'chef-inspec-gcp', region: 'europe-west2', name: 'gcp-inspec-test') do
it { should exist }
end
The following examples show how to use this InSpec audit resource.
describe google_compute_region_instance_group_manager(project: 'chef-inspec-gcp', region: 'europe-west2', name: 'gcp-inspec-test') do
its('target_size') { should eq 2 }
end
describe google_compute_region_instance_group_manager(project: 'chef-inspec-gcp', region: 'europe-west2', name: 'gcp-inspec-test') do
its('named_ports') { should include "http" }
end
base_instance_name
,creation_timestamp
,current_actions
,description
,fingerprint
,id
,instance_group
,instance_template
,kind
,name
,named_ports
,region
,self_link
,target_pools
,target_size
,region
Ensure the Compute Engine API is enabled for the project where the resource is located.