Project: Chef InSpec (Provisioning / Security & Compliance)
File: google_compute_forwarding_rules.md

+++ title = "googlecomputeforwarding_rules resource" draft = false gh_repo = "inspec" platform = "gcp" [menu] [menu.inspec] title = "googlecomputeforwarding_rules" identifier = "inspec/resources/gcp/googlecomputeforwardingrules.md googlecomputeforwardingrules resource" parent = "inspec/resources/gcp" +++ A `googlecomputeforwarding_rules` is used to test a Google ForwardingRule resource This resource has beta fields available. To retrieve these fields, include `beta: true` in the constructor for the resource ```ruby describe googlecomputeforwarding_rules(project: 'chef-gcp-inspec', region: 'europe-west2') do its('forwardingrulenames') { should include 'udp-forwarding-rule' } end ``` describe googlecomputeforwarding_rules(project: 'chef-inspec-gcp', region: 'europe-west2') do its('count') { should be <= 100} end describe googlecomputeforwarding_rules(project: 'chef-inspec-gcp', region: 'europe-west2') do its('forwardingruleids') { should include 12345678975432 } end describe googlecomputeforwarding_rules(project: 'chef-inspec-gcp', region: 'europe-west2') do its('forwardingrulenames') { should include "forwarding_rule-name" } end describe googlecomputeforwarding_rules(project: 'chef-inspec-gcp', region: 'europe-west2') do its('forwardingrulenetworks') { should not include "network-name" } end Properties that can be accessed from the `googlecomputeforwarding_rules` resource: See the resource for more information. `creation_timestamps` : an array of `googlecomputeforwardingrule` creationtimestamp `ismirroringcollectors` : (Beta only) an array of `googlecomputeforwardingrule` ismirroring_collector `descriptions` : an array of `googlecomputeforwarding_rule` description `forwardingruleids` : an array of `googlecomputeforwarding_rule` id `ip_addresses` : an array of `googlecomputeforwardingrule` ipaddress `ip_protocols` : an array of `googlecomputeforwardingrule` ipprotocol `backend_services` : an array of `googlecomputeforwardingrule` backendservice `forwardingruleloadbalancingschemes` : an array of `googlecomputeforwardingrule` loadbalancing_scheme `forwardingrulenames` : an array of `googlecomputeforwarding_rule` name `forwardingrulenetworks` : an array of `googlecomputeforwarding_rule` network `port_ranges` : an array of `googlecomputeforwardingrule` portrange `ports` : an array of `googlecomputeforwarding_rule` ports `subnetworks` : an array of `googlecomputeforwarding_rule` subnetwork `targets` : an array of `googlecomputeforwarding_rule` target `allowglobalaccesses` : an array of `googlecomputeforwardingrule` allowglobal_access `labels` : (Beta only) an array of `googlecomputeforwarding_rule` labels `label_fingerprints` : (Beta only) an array of `googlecomputeforwardingrule` labelfingerprint `all_ports` : an array of `googlecomputeforwardingrule` allports `network_tiers` : an array of `googlecomputeforwardingrule` networktier `service_labels` : an array of `googlecomputeforwardingrule` servicelabel `service_names` : an array of `googlecomputeforwardingrule` servicename `regions` : an array of `googlecomputeforwarding_rule` region This resource supports all of the above properties as filter criteria, which can be used with `where` as a block or a method. Ensure the is enabled for the current project.