Google Cloud Classic v7.29.0 published on Wednesday, Jun 26, 2024 by Pulumi
gcp.compute.getForwardingRule
Explore with Pulumi AI
Get a forwarding rule within GCE from its name.
Example Usage
data "google_compute_forwarding_rule" "my-forwarding-rule" {
  name = "forwarding-rule-us-east1"
}
Using getForwardingRule
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getForwardingRule(args: GetForwardingRuleArgs, opts?: InvokeOptions): Promise<GetForwardingRuleResult>
function getForwardingRuleOutput(args: GetForwardingRuleOutputArgs, opts?: InvokeOptions): Output<GetForwardingRuleResult>def get_forwarding_rule(name: Optional[str] = None,
                        project: Optional[str] = None,
                        region: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetForwardingRuleResult
def get_forwarding_rule_output(name: Optional[pulumi.Input[str]] = None,
                        project: Optional[pulumi.Input[str]] = None,
                        region: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetForwardingRuleResult]func LookupForwardingRule(ctx *Context, args *LookupForwardingRuleArgs, opts ...InvokeOption) (*LookupForwardingRuleResult, error)
func LookupForwardingRuleOutput(ctx *Context, args *LookupForwardingRuleOutputArgs, opts ...InvokeOption) LookupForwardingRuleResultOutput> Note: This function is named LookupForwardingRule in the Go SDK.
public static class GetForwardingRule 
{
    public static Task<GetForwardingRuleResult> InvokeAsync(GetForwardingRuleArgs args, InvokeOptions? opts = null)
    public static Output<GetForwardingRuleResult> Invoke(GetForwardingRuleInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetForwardingRuleResult> getForwardingRule(GetForwardingRuleArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: gcp:compute/getForwardingRule:getForwardingRule
  arguments:
    # arguments dictionaryThe following arguments are supported:
getForwardingRule Result
The following output properties are available:
- All
Ports bool - Allow
Global boolAccess  - Allow
Psc boolGlobal Access  - Backend
Service string - Base
Forwarding stringRule  - Creation
Timestamp string - Description string
 - Effective
Labels Dictionary<string, string> - Id string
 - The provider-assigned unique ID for this managed resource.
 - Ip
Address string - Ip
Protocol string - Ip
Version string - Is
Mirroring boolCollector  - Label
Fingerprint string - Labels Dictionary<string, string>
 - Load
Balancing stringScheme  - Name string
 - Network string
 - Network
Tier string - No
Automate boolDns Zone  - Port
Range string - Ports List<string>
 - Psc
Connection stringId  - Psc
Connection stringStatus  - Pulumi
Labels Dictionary<string, string> - Recreate
Closed boolPsc  - Self
Link string - Service
Directory List<GetRegistrations Forwarding Rule Service Directory Registration>  - Service
Label string - Service
Name string - Source
Ip List<string>Ranges  - Subnetwork string
 - Target string
 - Project string
 - Region string
 
- All
Ports bool - Allow
Global boolAccess  - Allow
Psc boolGlobal Access  - Backend
Service string - Base
Forwarding stringRule  - Creation
Timestamp string - Description string
 - Effective
Labels map[string]string - Id string
 - The provider-assigned unique ID for this managed resource.
 - Ip
Address string - Ip
Protocol string - Ip
Version string - Is
Mirroring boolCollector  - Label
Fingerprint string - Labels map[string]string
 - Load
Balancing stringScheme  - Name string
 - Network string
 - Network
Tier string - No
Automate boolDns Zone  - Port
Range string - Ports []string
 - Psc
Connection stringId  - Psc
Connection stringStatus  - Pulumi
Labels map[string]string - Recreate
Closed boolPsc  - Self
Link string - Service
Directory []GetRegistrations Forwarding Rule Service Directory Registration  - Service
Label string - Service
Name string - Source
Ip []stringRanges  - Subnetwork string
 - Target string
 - Project string
 - Region string
 
- all
Ports Boolean - allow
Global BooleanAccess  - allow
Psc BooleanGlobal Access  - backend
Service String - base
Forwarding StringRule  - creation
Timestamp String - description String
 - effective
Labels Map<String,String> - id String
 - The provider-assigned unique ID for this managed resource.
 - ip
Address String - ip
Protocol String - ip
Version String - is
Mirroring BooleanCollector  - label
Fingerprint String - labels Map<String,String>
 - load
Balancing StringScheme  - name String
 - network String
 - network
Tier String - no
Automate BooleanDns Zone  - port
Range String - ports List<String>
 - psc
Connection StringId  - psc
Connection StringStatus  - pulumi
Labels Map<String,String> - recreate
Closed BooleanPsc  - self
Link String - service
Directory List<GetRegistrations Forwarding Rule Service Directory Registration>  - service
Label String - service
Name String - source
Ip List<String>Ranges  - subnetwork String
 - target String
 - project String
 - region String
 
- all
Ports boolean - allow
Global booleanAccess  - allow
Psc booleanGlobal Access  - backend
Service string - base
Forwarding stringRule  - creation
Timestamp string - description string
 - effective
Labels {[key: string]: string} - id string
 - The provider-assigned unique ID for this managed resource.
 - ip
Address string - ip
Protocol string - ip
Version string - is
Mirroring booleanCollector  - label
Fingerprint string - labels {[key: string]: string}
 - load
Balancing stringScheme  - name string
 - network string
 - network
Tier string - no
Automate booleanDns Zone  - port
Range string - ports string[]
 - psc
Connection stringId  - psc
Connection stringStatus  - pulumi
Labels {[key: string]: string} - recreate
Closed booleanPsc  - self
Link string - service
Directory GetRegistrations Forwarding Rule Service Directory Registration[]  - service
Label string - service
Name string - source
Ip string[]Ranges  - subnetwork string
 - target string
 - project string
 - region string
 
- all_
ports bool - allow_
global_ boolaccess  - allow_
psc_ boolglobal_ access  - backend_
service str - base_
forwarding_ strrule  - creation_
timestamp str - description str
 - effective_
labels Mapping[str, str] - id str
 - The provider-assigned unique ID for this managed resource.
 - ip_
address str - ip_
protocol str - ip_
version str - is_
mirroring_ boolcollector  - label_
fingerprint str - labels Mapping[str, str]
 - load_
balancing_ strscheme  - name str
 - network str
 - network_
tier str - no_
automate_ booldns_ zone  - port_
range str - ports Sequence[str]
 - psc_
connection_ strid  - psc_
connection_ strstatus  - pulumi_
labels Mapping[str, str] - recreate_
closed_ boolpsc  - self_
link str - service_
directory_ Sequence[Getregistrations Forwarding Rule Service Directory Registration]  - service_
label str - service_
name str - source_
ip_ Sequence[str]ranges  - subnetwork str
 - target str
 - project str
 - region str
 
- all
Ports Boolean - allow
Global BooleanAccess  - allow
Psc BooleanGlobal Access  - backend
Service String - base
Forwarding StringRule  - creation
Timestamp String - description String
 - effective
Labels Map<String> - id String
 - The provider-assigned unique ID for this managed resource.
 - ip
Address String - ip
Protocol String - ip
Version String - is
Mirroring BooleanCollector  - label
Fingerprint String - labels Map<String>
 - load
Balancing StringScheme  - name String
 - network String
 - network
Tier String - no
Automate BooleanDns Zone  - port
Range String - ports List<String>
 - psc
Connection StringId  - psc
Connection StringStatus  - pulumi
Labels Map<String> - recreate
Closed BooleanPsc  - self
Link String - service
Directory List<Property Map>Registrations  - service
Label String - service
Name String - source
Ip List<String>Ranges  - subnetwork String
 - target String
 - project String
 - region String
 
Supporting Types
GetForwardingRuleServiceDirectoryRegistration     
Package Details
- Repository
 - Google Cloud (GCP) Classic pulumi/pulumi-gcp
 - License
 - Apache-2.0
 - Notes
 - This Pulumi package is based on the 
google-betaTerraform Provider.