FirewallRule
A single firewall rule that is evaluated against incoming traffic and provides an action to take on matched requests.
To get more information about FirewallRule, see:
- API documentation
- How-to Guides
Create a FirewallRule Resource
new FirewallRule(name: string, args: FirewallRuleArgs, opts?: CustomResourceOptions);def FirewallRule(resource_name, opts=None, action=None, description=None, priority=None, project=None, source_range=None, __props__=None);func NewFirewallRule(ctx *Context, name string, args FirewallRuleArgs, opts ...ResourceOption) (*FirewallRule, error)public FirewallRule(string name, FirewallRuleArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args FirewallRuleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args FirewallRuleArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FirewallRuleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
FirewallRule Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The FirewallRule resource accepts the following input properties:
- Action string
The action to take if this rule matches.
- Source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- Description string
An optional string description of this rule.
- Priority int
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Action string
The action to take if this rule matches.
- Source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- Description string
An optional string description of this rule.
- Priority int
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- action string
The action to take if this rule matches.
- source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- description string
An optional string description of this rule.
- priority number
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- action str
The action to take if this rule matches.
- source_
range str IP address or range, defined using CIDR notation, of requests that this rule applies to.
- description str
An optional string description of this rule.
- priority float
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
Outputs
All input properties are implicitly available as output properties. Additionally, the FirewallRule resource produces the following output properties:
Look up an Existing FirewallRule Resource
Get an existing FirewallRule resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: FirewallRuleState, opts?: CustomResourceOptions): FirewallRulestatic get(resource_name, id, opts=None, action=None, description=None, priority=None, project=None, source_range=None, __props__=None);func GetFirewallRule(ctx *Context, name string, id IDInput, state *FirewallRuleState, opts ...ResourceOption) (*FirewallRule, error)public static FirewallRule Get(string name, Input<string> id, FirewallRuleState? state, CustomResourceOptions? opts = null)- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
The following state arguments are supported:
- Action string
The action to take if this rule matches.
- Description string
An optional string description of this rule.
- Priority int
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- Action string
The action to take if this rule matches.
- Description string
An optional string description of this rule.
- Priority int
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- action string
The action to take if this rule matches.
- description string
An optional string description of this rule.
- priority number
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- source
Range string IP address or range, defined using CIDR notation, of requests that this rule applies to.
- action str
The action to take if this rule matches.
- description str
An optional string description of this rule.
- priority float
A positive integer that defines the order of rule evaluation. Rules with the lowest priority are evaluated first. A default rule at priority Int32.MaxValue matches all IPv4 and IPv6 traffic when no previous rule matches. Only the action of this rule can be modified by the user.
- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- source_
range str IP address or range, defined using CIDR notation, of requests that this rule applies to.
Package Details
- Repository
- https://github.com/pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-betaTerraform Provider.