DatabaseFirewall
Provides a DigitalOcean database firewall resource allowing you to restrict connections to your database to trusted sources. You may limit connections to specific Droplets, Kubernetes clusters, or IP addresses.
Create a DatabaseFirewall Resource
new DatabaseFirewall(name: string, args: DatabaseFirewallArgs, opts?: CustomResourceOptions);def DatabaseFirewall(resource_name, opts=None, cluster_id=None, rules=None, __props__=None);func NewDatabaseFirewall(ctx *Context, name string, args DatabaseFirewallArgs, opts ...ResourceOption) (*DatabaseFirewall, error)public DatabaseFirewall(string name, DatabaseFirewallArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args DatabaseFirewallArgs
- 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 DatabaseFirewallArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DatabaseFirewallArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
DatabaseFirewall Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The DatabaseFirewall resource accepts the following input properties:
- Cluster
Id string The ID of the target database cluster.
- Rules
List<Pulumi.
Digital Ocean. Inputs. Database Firewall Rule Args> A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- Cluster
Id string The ID of the target database cluster.
- Rules
[]Database
Firewall Rule A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- cluster
Id string The ID of the target database cluster.
- rules
Database
Firewall Rule[] A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- cluster_
id str The ID of the target database cluster.
- rules
List[Database
Firewall Rule] A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
Outputs
All input properties are implicitly available as output properties. Additionally, the DatabaseFirewall resource produces the following output properties:
Look up an Existing DatabaseFirewall Resource
Get an existing DatabaseFirewall 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?: DatabaseFirewallState, opts?: CustomResourceOptions): DatabaseFirewallstatic get(resource_name, id, opts=None, cluster_id=None, rules=None, __props__=None);func GetDatabaseFirewall(ctx *Context, name string, id IDInput, state *DatabaseFirewallState, opts ...ResourceOption) (*DatabaseFirewall, error)public static DatabaseFirewall Get(string name, Input<string> id, DatabaseFirewallState? 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:
- Cluster
Id string The ID of the target database cluster.
- Rules
List<Pulumi.
Digital Ocean. Inputs. Database Firewall Rule Args> A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- Cluster
Id string The ID of the target database cluster.
- Rules
[]Database
Firewall Rule A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- cluster
Id string The ID of the target database cluster.
- rules
Database
Firewall Rule[] A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
- cluster_
id str The ID of the target database cluster.
- rules
List[Database
Firewall Rule] A rule specifying a resource allowed to access the database cluster. The following arguments must be specified: -
type- (Required) The type of resource that the firewall rule allows to access the database cluster. The possible values are:droplet,k8s,ip_addr, ortag. -value- (Required) The ID of the specific resource, the name of a tag applied to a group of resources, or the IP address that the firewall rule allows to access the database cluster.
Supporting Types
DatabaseFirewallRule
Package Details
- Repository
- https://github.com/pulumi/pulumi-digitalocean
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
digitaloceanTerraform Provider.