1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. MysqlBackupDownloadRestriction
tencentcloud 1.81.183 published on Wednesday, Apr 16, 2025 by tencentcloudstack

tencentcloud.MysqlBackupDownloadRestriction

Explore with Pulumi AI

Provides a resource to create a mysql backup_download_restriction

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";

const example = new tencentcloud.MysqlBackupDownloadRestriction("example", {
    ipComparisonSymbol: "In",
    limitIps: ["127.0.0.1"],
    limitType: "Customize",
    limitVpcs: [{
        region: "ap-guangzhou",
        vpcLists: ["vpc-4owdpnwr"],
    }],
    vpcComparisonSymbol: "In",
});
Copy
import pulumi
import pulumi_tencentcloud as tencentcloud

example = tencentcloud.MysqlBackupDownloadRestriction("example",
    ip_comparison_symbol="In",
    limit_ips=["127.0.0.1"],
    limit_type="Customize",
    limit_vpcs=[{
        "region": "ap-guangzhou",
        "vpc_lists": ["vpc-4owdpnwr"],
    }],
    vpc_comparison_symbol="In")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := tencentcloud.NewMysqlBackupDownloadRestriction(ctx, "example", &tencentcloud.MysqlBackupDownloadRestrictionArgs{
			IpComparisonSymbol: pulumi.String("In"),
			LimitIps: pulumi.StringArray{
				pulumi.String("127.0.0.1"),
			},
			LimitType: pulumi.String("Customize"),
			LimitVpcs: tencentcloud.MysqlBackupDownloadRestrictionLimitVpcArray{
				&tencentcloud.MysqlBackupDownloadRestrictionLimitVpcArgs{
					Region: pulumi.String("ap-guangzhou"),
					VpcLists: pulumi.StringArray{
						pulumi.String("vpc-4owdpnwr"),
					},
				},
			},
			VpcComparisonSymbol: pulumi.String("In"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;

return await Deployment.RunAsync(() => 
{
    var example = new Tencentcloud.MysqlBackupDownloadRestriction("example", new()
    {
        IpComparisonSymbol = "In",
        LimitIps = new[]
        {
            "127.0.0.1",
        },
        LimitType = "Customize",
        LimitVpcs = new[]
        {
            new Tencentcloud.Inputs.MysqlBackupDownloadRestrictionLimitVpcArgs
            {
                Region = "ap-guangzhou",
                VpcLists = new[]
                {
                    "vpc-4owdpnwr",
                },
            },
        },
        VpcComparisonSymbol = "In",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.MysqlBackupDownloadRestriction;
import com.pulumi.tencentcloud.MysqlBackupDownloadRestrictionArgs;
import com.pulumi.tencentcloud.inputs.MysqlBackupDownloadRestrictionLimitVpcArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new MysqlBackupDownloadRestriction("example", MysqlBackupDownloadRestrictionArgs.builder()
            .ipComparisonSymbol("In")
            .limitIps("127.0.0.1")
            .limitType("Customize")
            .limitVpcs(MysqlBackupDownloadRestrictionLimitVpcArgs.builder()
                .region("ap-guangzhou")
                .vpcLists("vpc-4owdpnwr")
                .build())
            .vpcComparisonSymbol("In")
            .build());

    }
}
Copy
resources:
  example:
    type: tencentcloud:MysqlBackupDownloadRestriction
    properties:
      ipComparisonSymbol: In
      limitIps:
        - 127.0.0.1
      limitType: Customize
      limitVpcs:
        - region: ap-guangzhou
          vpcLists:
            - vpc-4owdpnwr
      vpcComparisonSymbol: In
Copy

Create MysqlBackupDownloadRestriction Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new MysqlBackupDownloadRestriction(name: string, args: MysqlBackupDownloadRestrictionArgs, opts?: CustomResourceOptions);
@overload
def MysqlBackupDownloadRestriction(resource_name: str,
                                   args: MysqlBackupDownloadRestrictionArgs,
                                   opts: Optional[ResourceOptions] = None)

@overload
def MysqlBackupDownloadRestriction(resource_name: str,
                                   opts: Optional[ResourceOptions] = None,
                                   limit_type: Optional[str] = None,
                                   ip_comparison_symbol: Optional[str] = None,
                                   limit_ips: Optional[Sequence[str]] = None,
                                   limit_vpcs: Optional[Sequence[MysqlBackupDownloadRestrictionLimitVpcArgs]] = None,
                                   mysql_backup_download_restriction_id: Optional[str] = None,
                                   vpc_comparison_symbol: Optional[str] = None)
func NewMysqlBackupDownloadRestriction(ctx *Context, name string, args MysqlBackupDownloadRestrictionArgs, opts ...ResourceOption) (*MysqlBackupDownloadRestriction, error)
public MysqlBackupDownloadRestriction(string name, MysqlBackupDownloadRestrictionArgs args, CustomResourceOptions? opts = null)
public MysqlBackupDownloadRestriction(String name, MysqlBackupDownloadRestrictionArgs args)
public MysqlBackupDownloadRestriction(String name, MysqlBackupDownloadRestrictionArgs args, CustomResourceOptions options)
type: tencentcloud:MysqlBackupDownloadRestriction
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. MysqlBackupDownloadRestrictionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. MysqlBackupDownloadRestrictionArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. MysqlBackupDownloadRestrictionArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. MysqlBackupDownloadRestrictionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. MysqlBackupDownloadRestrictionArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

MysqlBackupDownloadRestriction Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The MysqlBackupDownloadRestriction resource accepts the following input properties:

LimitType This property is required. string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
IpComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
LimitIps List<string>
ip settings to limit downloads.
LimitVpcs List<MysqlBackupDownloadRestrictionLimitVpc>
vpc settings to limit downloads.
MysqlBackupDownloadRestrictionId string
ID of the resource.
VpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
LimitType This property is required. string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
IpComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
LimitIps []string
ip settings to limit downloads.
LimitVpcs []MysqlBackupDownloadRestrictionLimitVpcArgs
vpc settings to limit downloads.
MysqlBackupDownloadRestrictionId string
ID of the resource.
VpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
limitType This property is required. String
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
ipComparisonSymbol String
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps List<String>
ip settings to limit downloads.
limitVpcs List<MysqlBackupDownloadRestrictionLimitVpc>
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId String
ID of the resource.
vpcComparisonSymbol String
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
limitType This property is required. string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
ipComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps string[]
ip settings to limit downloads.
limitVpcs MysqlBackupDownloadRestrictionLimitVpc[]
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId string
ID of the resource.
vpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
limit_type This property is required. str
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
ip_comparison_symbol str
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limit_ips Sequence[str]
ip settings to limit downloads.
limit_vpcs Sequence[MysqlBackupDownloadRestrictionLimitVpcArgs]
vpc settings to limit downloads.
mysql_backup_download_restriction_id str
ID of the resource.
vpc_comparison_symbol str
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
limitType This property is required. String
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
ipComparisonSymbol String
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps List<String>
ip settings to limit downloads.
limitVpcs List<Property Map>
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId String
ID of the resource.
vpcComparisonSymbol String
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.

Outputs

All input properties are implicitly available as output properties. Additionally, the MysqlBackupDownloadRestriction resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing MysqlBackupDownloadRestriction Resource

Get an existing MysqlBackupDownloadRestriction 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?: MysqlBackupDownloadRestrictionState, opts?: CustomResourceOptions): MysqlBackupDownloadRestriction
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        ip_comparison_symbol: Optional[str] = None,
        limit_ips: Optional[Sequence[str]] = None,
        limit_type: Optional[str] = None,
        limit_vpcs: Optional[Sequence[MysqlBackupDownloadRestrictionLimitVpcArgs]] = None,
        mysql_backup_download_restriction_id: Optional[str] = None,
        vpc_comparison_symbol: Optional[str] = None) -> MysqlBackupDownloadRestriction
func GetMysqlBackupDownloadRestriction(ctx *Context, name string, id IDInput, state *MysqlBackupDownloadRestrictionState, opts ...ResourceOption) (*MysqlBackupDownloadRestriction, error)
public static MysqlBackupDownloadRestriction Get(string name, Input<string> id, MysqlBackupDownloadRestrictionState? state, CustomResourceOptions? opts = null)
public static MysqlBackupDownloadRestriction get(String name, Output<String> id, MysqlBackupDownloadRestrictionState state, CustomResourceOptions options)
resources:  _:    type: tencentcloud:MysqlBackupDownloadRestriction    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
IpComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
LimitIps List<string>
ip settings to limit downloads.
LimitType string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
LimitVpcs List<MysqlBackupDownloadRestrictionLimitVpc>
vpc settings to limit downloads.
MysqlBackupDownloadRestrictionId string
ID of the resource.
VpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
IpComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
LimitIps []string
ip settings to limit downloads.
LimitType string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
LimitVpcs []MysqlBackupDownloadRestrictionLimitVpcArgs
vpc settings to limit downloads.
MysqlBackupDownloadRestrictionId string
ID of the resource.
VpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
ipComparisonSymbol String
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps List<String>
ip settings to limit downloads.
limitType String
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
limitVpcs List<MysqlBackupDownloadRestrictionLimitVpc>
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId String
ID of the resource.
vpcComparisonSymbol String
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
ipComparisonSymbol string
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps string[]
ip settings to limit downloads.
limitType string
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
limitVpcs MysqlBackupDownloadRestrictionLimitVpc[]
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId string
ID of the resource.
vpcComparisonSymbol string
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
ip_comparison_symbol str
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limit_ips Sequence[str]
ip settings to limit downloads.
limit_type str
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
limit_vpcs Sequence[MysqlBackupDownloadRestrictionLimitVpcArgs]
vpc settings to limit downloads.
mysql_backup_download_restriction_id str
ID of the resource.
vpc_comparison_symbol str
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.
ipComparisonSymbol String
In: The specified ip can be downloaded; NotIn: The specified ip cannot be downloaded. The default is In.
limitIps List<String>
ip settings to limit downloads.
limitType String
NoLimit No limit, both internal and external networks can be downloaded; LimitOnlyIntranet Only intranet can be downloaded; Customize user-defined vpc:ip can be downloaded. LimitVpc and LimitIp can be set only when the value is Customize.
limitVpcs List<Property Map>
vpc settings to limit downloads.
mysqlBackupDownloadRestrictionId String
ID of the resource.
vpcComparisonSymbol String
This parameter only supports In, which means that the vpc specified by LimitVpc can be downloaded. The default is In.

Supporting Types

MysqlBackupDownloadRestrictionLimitVpc
, MysqlBackupDownloadRestrictionLimitVpcArgs

Region This property is required. string
Restrict downloads from regions. Currently only the current region is supported.
VpcLists This property is required. List<string>
List of vpcs to limit downloads.
Region This property is required. string
Restrict downloads from regions. Currently only the current region is supported.
VpcLists This property is required. []string
List of vpcs to limit downloads.
region This property is required. String
Restrict downloads from regions. Currently only the current region is supported.
vpcLists This property is required. List<String>
List of vpcs to limit downloads.
region This property is required. string
Restrict downloads from regions. Currently only the current region is supported.
vpcLists This property is required. string[]
List of vpcs to limit downloads.
region This property is required. str
Restrict downloads from regions. Currently only the current region is supported.
vpc_lists This property is required. Sequence[str]
List of vpcs to limit downloads.
region This property is required. String
Restrict downloads from regions. Currently only the current region is supported.
vpcLists This property is required. List<String>
List of vpcs to limit downloads.

Import

mysql backup_download_restriction can be imported using the “BackupDownloadRestriction”, as follows.

$ pulumi import tencentcloud:index/mysqlBackupDownloadRestriction:MysqlBackupDownloadRestriction backup_download_restriction BackupDownloadRestriction
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
tencentcloud tencentcloudstack/terraform-provider-tencentcloud
License
Notes
This Pulumi package is based on the tencentcloud Terraform Provider.