tencentcloud.PostgresqlCloneDbInstance
Explore with Pulumi AI
Provides a resource to create a postgresql clone db instance
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.PostgresqlCloneDbInstance("example", {
    autoRenewFlag: 0,
    dbInstanceId: "postgres-evsqpyap",
    dbNodeSets: [
        {
            role: "Primary",
            zone: "ap-guangzhou-6",
        },
        {
            role: "Standby",
            zone: "ap-guangzhou-6",
        },
    ],
    instanceChargeType: "POSTPAID_BY_HOUR",
    period: 1,
    projectId: 0,
    recoveryTargetTime: "2024-10-12 18:17:00",
    securityGroupIds: ["sg-8stavs03"],
    specCode: "pg.it.medium4",
    storage: 200,
    subnetId: "subnet-b8hintyy",
    tagLists: [{
        tagKey: "createBy",
        tagValue: "terraform",
    }],
    vpcId: "vpc-a6zec4mf",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.PostgresqlCloneDbInstance("example",
    auto_renew_flag=0,
    db_instance_id="postgres-evsqpyap",
    db_node_sets=[
        {
            "role": "Primary",
            "zone": "ap-guangzhou-6",
        },
        {
            "role": "Standby",
            "zone": "ap-guangzhou-6",
        },
    ],
    instance_charge_type="POSTPAID_BY_HOUR",
    period=1,
    project_id=0,
    recovery_target_time="2024-10-12 18:17:00",
    security_group_ids=["sg-8stavs03"],
    spec_code="pg.it.medium4",
    storage=200,
    subnet_id="subnet-b8hintyy",
    tag_lists=[{
        "tag_key": "createBy",
        "tag_value": "terraform",
    }],
    vpc_id="vpc-a6zec4mf")
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.NewPostgresqlCloneDbInstance(ctx, "example", &tencentcloud.PostgresqlCloneDbInstanceArgs{
			AutoRenewFlag: pulumi.Float64(0),
			DbInstanceId:  pulumi.String("postgres-evsqpyap"),
			DbNodeSets: tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArray{
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					Role: pulumi.String("Primary"),
					Zone: pulumi.String("ap-guangzhou-6"),
				},
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					Role: pulumi.String("Standby"),
					Zone: pulumi.String("ap-guangzhou-6"),
				},
			},
			InstanceChargeType: pulumi.String("POSTPAID_BY_HOUR"),
			Period:             pulumi.Float64(1),
			ProjectId:          pulumi.Float64(0),
			RecoveryTargetTime: pulumi.String("2024-10-12 18:17:00"),
			SecurityGroupIds: pulumi.StringArray{
				pulumi.String("sg-8stavs03"),
			},
			SpecCode: pulumi.String("pg.it.medium4"),
			Storage:  pulumi.Float64(200),
			SubnetId: pulumi.String("subnet-b8hintyy"),
			TagLists: tencentcloud.PostgresqlCloneDbInstanceTagListArray{
				&tencentcloud.PostgresqlCloneDbInstanceTagListArgs{
					TagKey:   pulumi.String("createBy"),
					TagValue: pulumi.String("terraform"),
				},
			},
			VpcId: pulumi.String("vpc-a6zec4mf"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var example = new Tencentcloud.PostgresqlCloneDbInstance("example", new()
    {
        AutoRenewFlag = 0,
        DbInstanceId = "postgres-evsqpyap",
        DbNodeSets = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                Role = "Primary",
                Zone = "ap-guangzhou-6",
            },
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                Role = "Standby",
                Zone = "ap-guangzhou-6",
            },
        },
        InstanceChargeType = "POSTPAID_BY_HOUR",
        Period = 1,
        ProjectId = 0,
        RecoveryTargetTime = "2024-10-12 18:17:00",
        SecurityGroupIds = new[]
        {
            "sg-8stavs03",
        },
        SpecCode = "pg.it.medium4",
        Storage = 200,
        SubnetId = "subnet-b8hintyy",
        TagLists = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceTagListArgs
            {
                TagKey = "createBy",
                TagValue = "terraform",
            },
        },
        VpcId = "vpc-a6zec4mf",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstance;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstanceArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceDbNodeSetArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceTagListArgs;
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 PostgresqlCloneDbInstance("example", PostgresqlCloneDbInstanceArgs.builder()
            .autoRenewFlag(0)
            .dbInstanceId("postgres-evsqpyap")
            .dbNodeSets(            
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .role("Primary")
                    .zone("ap-guangzhou-6")
                    .build(),
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .role("Standby")
                    .zone("ap-guangzhou-6")
                    .build())
            .instanceChargeType("POSTPAID_BY_HOUR")
            .period(1)
            .projectId(0)
            .recoveryTargetTime("2024-10-12 18:17:00")
            .securityGroupIds("sg-8stavs03")
            .specCode("pg.it.medium4")
            .storage(200)
            .subnetId("subnet-b8hintyy")
            .tagLists(PostgresqlCloneDbInstanceTagListArgs.builder()
                .tagKey("createBy")
                .tagValue("terraform")
                .build())
            .vpcId("vpc-a6zec4mf")
            .build());
    }
}
resources:
  example:
    type: tencentcloud:PostgresqlCloneDbInstance
    properties:
      autoRenewFlag: 0
      dbInstanceId: postgres-evsqpyap
      dbNodeSets:
        - role: Primary
          zone: ap-guangzhou-6
        - role: Standby
          zone: ap-guangzhou-6
      instanceChargeType: POSTPAID_BY_HOUR
      period: 1
      projectId: 0
      recoveryTargetTime: 2024-10-12 18:17:00
      securityGroupIds:
        - sg-8stavs03
      specCode: pg.it.medium4
      storage: 200
      subnetId: subnet-b8hintyy
      tagLists:
        - tagKey: createBy
          tagValue: terraform
      vpcId: vpc-a6zec4mf
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const baseBackups = tencentcloud.getPostgresqlBaseBackups({
    filters: [{
        name: "db-instance-id",
        values: ["postgres-evsqpyap"],
    }],
    orderBy: "Size",
    orderByType: "asc",
});
const example = new tencentcloud.PostgresqlCloneDbInstance("example", {
    dbInstanceId: "postgres-evsqpyap",
    specCode: "pg.it.medium4",
    storage: 200,
    period: 1,
    autoRenewFlag: 0,
    vpcId: "vpc-a6zec4mf",
    subnetId: "subnet-b8hintyy",
    instanceChargeType: "POSTPAID_BY_HOUR",
    securityGroupIds: ["sg-8stavs03"],
    projectId: 0,
    backupSetId: baseBackups.then(baseBackups => baseBackups.baseBackupSets?.[0]?.id),
    dbNodeSets: [
        {
            role: "Primary",
            zone: "ap-guangzhou-6",
        },
        {
            role: "Standby",
            zone: "ap-guangzhou-6",
        },
    ],
    tagLists: [{
        tagKey: "createBy",
        tagValue: "terraform",
    }],
});
import pulumi
import pulumi_tencentcloud as tencentcloud
base_backups = tencentcloud.get_postgresql_base_backups(filters=[{
        "name": "db-instance-id",
        "values": ["postgres-evsqpyap"],
    }],
    order_by="Size",
    order_by_type="asc")
example = tencentcloud.PostgresqlCloneDbInstance("example",
    db_instance_id="postgres-evsqpyap",
    spec_code="pg.it.medium4",
    storage=200,
    period=1,
    auto_renew_flag=0,
    vpc_id="vpc-a6zec4mf",
    subnet_id="subnet-b8hintyy",
    instance_charge_type="POSTPAID_BY_HOUR",
    security_group_ids=["sg-8stavs03"],
    project_id=0,
    backup_set_id=base_backups.base_backup_sets[0].id,
    db_node_sets=[
        {
            "role": "Primary",
            "zone": "ap-guangzhou-6",
        },
        {
            "role": "Standby",
            "zone": "ap-guangzhou-6",
        },
    ],
    tag_lists=[{
        "tag_key": "createBy",
        "tag_value": "terraform",
    }])
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 {
		baseBackups, err := tencentcloud.GetPostgresqlBaseBackups(ctx, &tencentcloud.GetPostgresqlBaseBackupsArgs{
			Filters: []tencentcloud.GetPostgresqlBaseBackupsFilter{
				{
					Name: pulumi.StringRef("db-instance-id"),
					Values: []string{
						"postgres-evsqpyap",
					},
				},
			},
			OrderBy:     pulumi.StringRef("Size"),
			OrderByType: pulumi.StringRef("asc"),
		}, nil)
		if err != nil {
			return err
		}
		_, err = tencentcloud.NewPostgresqlCloneDbInstance(ctx, "example", &tencentcloud.PostgresqlCloneDbInstanceArgs{
			DbInstanceId:       pulumi.String("postgres-evsqpyap"),
			SpecCode:           pulumi.String("pg.it.medium4"),
			Storage:            pulumi.Float64(200),
			Period:             pulumi.Float64(1),
			AutoRenewFlag:      pulumi.Float64(0),
			VpcId:              pulumi.String("vpc-a6zec4mf"),
			SubnetId:           pulumi.String("subnet-b8hintyy"),
			InstanceChargeType: pulumi.String("POSTPAID_BY_HOUR"),
			SecurityGroupIds: pulumi.StringArray{
				pulumi.String("sg-8stavs03"),
			},
			ProjectId:   pulumi.Float64(0),
			BackupSetId: pulumi.String(baseBackups.BaseBackupSets[0].Id),
			DbNodeSets: tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArray{
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					Role: pulumi.String("Primary"),
					Zone: pulumi.String("ap-guangzhou-6"),
				},
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					Role: pulumi.String("Standby"),
					Zone: pulumi.String("ap-guangzhou-6"),
				},
			},
			TagLists: tencentcloud.PostgresqlCloneDbInstanceTagListArray{
				&tencentcloud.PostgresqlCloneDbInstanceTagListArgs{
					TagKey:   pulumi.String("createBy"),
					TagValue: pulumi.String("terraform"),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var baseBackups = Tencentcloud.GetPostgresqlBaseBackups.Invoke(new()
    {
        Filters = new[]
        {
            new Tencentcloud.Inputs.GetPostgresqlBaseBackupsFilterInputArgs
            {
                Name = "db-instance-id",
                Values = new[]
                {
                    "postgres-evsqpyap",
                },
            },
        },
        OrderBy = "Size",
        OrderByType = "asc",
    });
    var example = new Tencentcloud.PostgresqlCloneDbInstance("example", new()
    {
        DbInstanceId = "postgres-evsqpyap",
        SpecCode = "pg.it.medium4",
        Storage = 200,
        Period = 1,
        AutoRenewFlag = 0,
        VpcId = "vpc-a6zec4mf",
        SubnetId = "subnet-b8hintyy",
        InstanceChargeType = "POSTPAID_BY_HOUR",
        SecurityGroupIds = new[]
        {
            "sg-8stavs03",
        },
        ProjectId = 0,
        BackupSetId = baseBackups.Apply(getPostgresqlBaseBackupsResult => getPostgresqlBaseBackupsResult.BaseBackupSets[0]?.Id),
        DbNodeSets = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                Role = "Primary",
                Zone = "ap-guangzhou-6",
            },
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                Role = "Standby",
                Zone = "ap-guangzhou-6",
            },
        },
        TagLists = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceTagListArgs
            {
                TagKey = "createBy",
                TagValue = "terraform",
            },
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.TencentcloudFunctions;
import com.pulumi.tencentcloud.inputs.GetPostgresqlBaseBackupsArgs;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstance;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstanceArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceDbNodeSetArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceTagListArgs;
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) {
        final var baseBackups = TencentcloudFunctions.getPostgresqlBaseBackups(GetPostgresqlBaseBackupsArgs.builder()
            .filters(GetPostgresqlBaseBackupsFilterArgs.builder()
                .name("db-instance-id")
                .values("postgres-evsqpyap")
                .build())
            .orderBy("Size")
            .orderByType("asc")
            .build());
        var example = new PostgresqlCloneDbInstance("example", PostgresqlCloneDbInstanceArgs.builder()
            .dbInstanceId("postgres-evsqpyap")
            .specCode("pg.it.medium4")
            .storage(200)
            .period(1)
            .autoRenewFlag(0)
            .vpcId("vpc-a6zec4mf")
            .subnetId("subnet-b8hintyy")
            .instanceChargeType("POSTPAID_BY_HOUR")
            .securityGroupIds("sg-8stavs03")
            .projectId(0)
            .backupSetId(baseBackups.applyValue(getPostgresqlBaseBackupsResult -> getPostgresqlBaseBackupsResult.baseBackupSets()[0].id()))
            .dbNodeSets(            
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .role("Primary")
                    .zone("ap-guangzhou-6")
                    .build(),
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .role("Standby")
                    .zone("ap-guangzhou-6")
                    .build())
            .tagLists(PostgresqlCloneDbInstanceTagListArgs.builder()
                .tagKey("createBy")
                .tagValue("terraform")
                .build())
            .build());
    }
}
resources:
  example:
    type: tencentcloud:PostgresqlCloneDbInstance
    properties:
      dbInstanceId: postgres-evsqpyap
      specCode: pg.it.medium4
      storage: 200
      period: 1
      autoRenewFlag: 0
      vpcId: vpc-a6zec4mf
      subnetId: subnet-b8hintyy
      instanceChargeType: POSTPAID_BY_HOUR
      securityGroupIds:
        - sg-8stavs03
      projectId: 0
      backupSetId: ${baseBackups.baseBackupSets[0].id}
      dbNodeSets:
        - role: Primary
          zone: ap-guangzhou-6
        - role: Standby
          zone: ap-guangzhou-6
      tagLists:
        - tagKey: createBy
          tagValue: terraform
variables:
  baseBackups:
    fn::invoke:
      function: tencentcloud:getPostgresqlBaseBackups
      arguments:
        filters:
          - name: db-instance-id
            values:
              - postgres-evsqpyap
        orderBy: Size
        orderByType: asc
Clone db instance from CDC
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.PostgresqlCloneDbInstance("example", {
    autoRenewFlag: 0,
    dbInstanceId: "postgres-evsqpyap",
    dbNodeSets: [
        {
            dedicatedClusterId: "cluster-262n63e8",
            role: "Primary",
            zone: "ap-guangzhou-6",
        },
        {
            dedicatedClusterId: "cluster-262n63e8",
            role: "Standby",
            zone: "ap-guangzhou-6",
        },
    ],
    instanceChargeType: "POSTPAID_BY_HOUR",
    period: 1,
    projectId: 0,
    recoveryTargetTime: "2024-10-12 18:17:00",
    securityGroupIds: ["sg-8stavs03"],
    specCode: "pg.it.medium4",
    storage: 200,
    subnetId: "subnet-b8hintyy",
    tagLists: [{
        tagKey: "createBy",
        tagValue: "terraform",
    }],
    vpcId: "vpc-a6zec4mf",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.PostgresqlCloneDbInstance("example",
    auto_renew_flag=0,
    db_instance_id="postgres-evsqpyap",
    db_node_sets=[
        {
            "dedicated_cluster_id": "cluster-262n63e8",
            "role": "Primary",
            "zone": "ap-guangzhou-6",
        },
        {
            "dedicated_cluster_id": "cluster-262n63e8",
            "role": "Standby",
            "zone": "ap-guangzhou-6",
        },
    ],
    instance_charge_type="POSTPAID_BY_HOUR",
    period=1,
    project_id=0,
    recovery_target_time="2024-10-12 18:17:00",
    security_group_ids=["sg-8stavs03"],
    spec_code="pg.it.medium4",
    storage=200,
    subnet_id="subnet-b8hintyy",
    tag_lists=[{
        "tag_key": "createBy",
        "tag_value": "terraform",
    }],
    vpc_id="vpc-a6zec4mf")
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.NewPostgresqlCloneDbInstance(ctx, "example", &tencentcloud.PostgresqlCloneDbInstanceArgs{
			AutoRenewFlag: pulumi.Float64(0),
			DbInstanceId:  pulumi.String("postgres-evsqpyap"),
			DbNodeSets: tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArray{
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					DedicatedClusterId: pulumi.String("cluster-262n63e8"),
					Role:               pulumi.String("Primary"),
					Zone:               pulumi.String("ap-guangzhou-6"),
				},
				&tencentcloud.PostgresqlCloneDbInstanceDbNodeSetArgs{
					DedicatedClusterId: pulumi.String("cluster-262n63e8"),
					Role:               pulumi.String("Standby"),
					Zone:               pulumi.String("ap-guangzhou-6"),
				},
			},
			InstanceChargeType: pulumi.String("POSTPAID_BY_HOUR"),
			Period:             pulumi.Float64(1),
			ProjectId:          pulumi.Float64(0),
			RecoveryTargetTime: pulumi.String("2024-10-12 18:17:00"),
			SecurityGroupIds: pulumi.StringArray{
				pulumi.String("sg-8stavs03"),
			},
			SpecCode: pulumi.String("pg.it.medium4"),
			Storage:  pulumi.Float64(200),
			SubnetId: pulumi.String("subnet-b8hintyy"),
			TagLists: tencentcloud.PostgresqlCloneDbInstanceTagListArray{
				&tencentcloud.PostgresqlCloneDbInstanceTagListArgs{
					TagKey:   pulumi.String("createBy"),
					TagValue: pulumi.String("terraform"),
				},
			},
			VpcId: pulumi.String("vpc-a6zec4mf"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var example = new Tencentcloud.PostgresqlCloneDbInstance("example", new()
    {
        AutoRenewFlag = 0,
        DbInstanceId = "postgres-evsqpyap",
        DbNodeSets = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                DedicatedClusterId = "cluster-262n63e8",
                Role = "Primary",
                Zone = "ap-guangzhou-6",
            },
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceDbNodeSetArgs
            {
                DedicatedClusterId = "cluster-262n63e8",
                Role = "Standby",
                Zone = "ap-guangzhou-6",
            },
        },
        InstanceChargeType = "POSTPAID_BY_HOUR",
        Period = 1,
        ProjectId = 0,
        RecoveryTargetTime = "2024-10-12 18:17:00",
        SecurityGroupIds = new[]
        {
            "sg-8stavs03",
        },
        SpecCode = "pg.it.medium4",
        Storage = 200,
        SubnetId = "subnet-b8hintyy",
        TagLists = new[]
        {
            new Tencentcloud.Inputs.PostgresqlCloneDbInstanceTagListArgs
            {
                TagKey = "createBy",
                TagValue = "terraform",
            },
        },
        VpcId = "vpc-a6zec4mf",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstance;
import com.pulumi.tencentcloud.PostgresqlCloneDbInstanceArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceDbNodeSetArgs;
import com.pulumi.tencentcloud.inputs.PostgresqlCloneDbInstanceTagListArgs;
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 PostgresqlCloneDbInstance("example", PostgresqlCloneDbInstanceArgs.builder()
            .autoRenewFlag(0)
            .dbInstanceId("postgres-evsqpyap")
            .dbNodeSets(            
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .dedicatedClusterId("cluster-262n63e8")
                    .role("Primary")
                    .zone("ap-guangzhou-6")
                    .build(),
                PostgresqlCloneDbInstanceDbNodeSetArgs.builder()
                    .dedicatedClusterId("cluster-262n63e8")
                    .role("Standby")
                    .zone("ap-guangzhou-6")
                    .build())
            .instanceChargeType("POSTPAID_BY_HOUR")
            .period(1)
            .projectId(0)
            .recoveryTargetTime("2024-10-12 18:17:00")
            .securityGroupIds("sg-8stavs03")
            .specCode("pg.it.medium4")
            .storage(200)
            .subnetId("subnet-b8hintyy")
            .tagLists(PostgresqlCloneDbInstanceTagListArgs.builder()
                .tagKey("createBy")
                .tagValue("terraform")
                .build())
            .vpcId("vpc-a6zec4mf")
            .build());
    }
}
resources:
  example:
    type: tencentcloud:PostgresqlCloneDbInstance
    properties:
      autoRenewFlag: 0
      dbInstanceId: postgres-evsqpyap
      dbNodeSets:
        - dedicatedClusterId: cluster-262n63e8
          role: Primary
          zone: ap-guangzhou-6
        - dedicatedClusterId: cluster-262n63e8
          role: Standby
          zone: ap-guangzhou-6
      instanceChargeType: POSTPAID_BY_HOUR
      period: 1
      projectId: 0
      recoveryTargetTime: 2024-10-12 18:17:00
      securityGroupIds:
        - sg-8stavs03
      specCode: pg.it.medium4
      storage: 200
      subnetId: subnet-b8hintyy
      tagLists:
        - tagKey: createBy
          tagValue: terraform
      vpcId: vpc-a6zec4mf
Create PostgresqlCloneDbInstance Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new PostgresqlCloneDbInstance(name: string, args: PostgresqlCloneDbInstanceArgs, opts?: CustomResourceOptions);@overload
def PostgresqlCloneDbInstance(resource_name: str,
                              args: PostgresqlCloneDbInstanceArgs,
                              opts: Optional[ResourceOptions] = None)
@overload
def PostgresqlCloneDbInstance(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              period: Optional[float] = None,
                              auto_renew_flag: Optional[float] = None,
                              vpc_id: Optional[str] = None,
                              db_instance_id: Optional[str] = None,
                              subnet_id: Optional[str] = None,
                              storage: Optional[float] = None,
                              spec_code: Optional[str] = None,
                              db_node_sets: Optional[Sequence[PostgresqlCloneDbInstanceDbNodeSetArgs]] = None,
                              postgresql_clone_db_instance_id: Optional[str] = None,
                              project_id: Optional[float] = None,
                              recovery_target_time: Optional[str] = None,
                              security_group_ids: Optional[Sequence[str]] = None,
                              name: Optional[str] = None,
                              instance_charge_type: Optional[str] = None,
                              activity_id: Optional[float] = None,
                              sync_mode: Optional[str] = None,
                              tag_lists: Optional[Sequence[PostgresqlCloneDbInstanceTagListArgs]] = None,
                              backup_set_id: Optional[str] = None)func NewPostgresqlCloneDbInstance(ctx *Context, name string, args PostgresqlCloneDbInstanceArgs, opts ...ResourceOption) (*PostgresqlCloneDbInstance, error)public PostgresqlCloneDbInstance(string name, PostgresqlCloneDbInstanceArgs args, CustomResourceOptions? opts = null)
public PostgresqlCloneDbInstance(String name, PostgresqlCloneDbInstanceArgs args)
public PostgresqlCloneDbInstance(String name, PostgresqlCloneDbInstanceArgs args, CustomResourceOptions options)
type: tencentcloud:PostgresqlCloneDbInstance
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args PostgresqlCloneDbInstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args PostgresqlCloneDbInstanceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args PostgresqlCloneDbInstanceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args PostgresqlCloneDbInstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args PostgresqlCloneDbInstanceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
PostgresqlCloneDbInstance 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 PostgresqlCloneDbInstance resource accepts the following input properties:
- AutoRenew doubleFlag 
- Renewal Flag:
- DbInstance stringId 
- ID of the original instance to be cloned.
- Period double
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- SpecCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- Storage double
- Instance storage capacity in GB.
- SubnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- VpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- ActivityId double
- Campaign ID.
- BackupSet stringId 
- Basic backup set ID.
- DbNode List<PostgresqlSets Clone Db Instance Db Node Set> 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- InstanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- Name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- PostgresqlClone stringDb Instance Id 
- ID of the resource.
- ProjectId double
- Project ID.
- RecoveryTarget stringTime 
- Restoration point in time.
- SecurityGroup List<string>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- SyncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- TagLists List<PostgresqlClone Db Instance Tag List> 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- AutoRenew float64Flag 
- Renewal Flag:
- DbInstance stringId 
- ID of the original instance to be cloned.
- Period float64
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- SpecCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- Storage float64
- Instance storage capacity in GB.
- SubnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- VpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- ActivityId float64
- Campaign ID.
- BackupSet stringId 
- Basic backup set ID.
- DbNode []PostgresqlSets Clone Db Instance Db Node Set Args 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- InstanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- Name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- PostgresqlClone stringDb Instance Id 
- ID of the resource.
- ProjectId float64
- Project ID.
- RecoveryTarget stringTime 
- Restoration point in time.
- SecurityGroup []stringIds 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- SyncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- TagLists []PostgresqlClone Db Instance Tag List Args 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- autoRenew DoubleFlag 
- Renewal Flag:
- dbInstance StringId 
- ID of the original instance to be cloned.
- period Double
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- specCode String
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage Double
- Instance storage capacity in GB.
- subnetId String
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- vpcId String
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId Double
- Campaign ID.
- backupSet StringId 
- Basic backup set ID.
- dbNode List<PostgresqlSets Clone Db Instance Db Node Set> 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge StringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name String
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- postgresqlClone StringDb Instance Id 
- ID of the resource.
- projectId Double
- Project ID.
- recoveryTarget StringTime 
- Restoration point in time.
- securityGroup List<String>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- syncMode String
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists List<PostgresqlClone Db Instance Tag List> 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- autoRenew numberFlag 
- Renewal Flag:
- dbInstance stringId 
- ID of the original instance to be cloned.
- period number
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- specCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage number
- Instance storage capacity in GB.
- subnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- vpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId number
- Campaign ID.
- backupSet stringId 
- Basic backup set ID.
- dbNode PostgresqlSets Clone Db Instance Db Node Set[] 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- postgresqlClone stringDb Instance Id 
- ID of the resource.
- projectId number
- Project ID.
- recoveryTarget stringTime 
- Restoration point in time.
- securityGroup string[]Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- syncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists PostgresqlClone Db Instance Tag List[] 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- auto_renew_ floatflag 
- Renewal Flag:
- db_instance_ strid 
- ID of the original instance to be cloned.
- period float
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- spec_code str
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage float
- Instance storage capacity in GB.
- subnet_id str
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- vpc_id str
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activity_id float
- Campaign ID.
- backup_set_ strid 
- Basic backup set ID.
- db_node_ Sequence[Postgresqlsets Clone Db Instance Db Node Set Args] 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instance_charge_ strtype 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name str
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- postgresql_clone_ strdb_ instance_ id 
- ID of the resource.
- project_id float
- Project ID.
- recovery_target_ strtime 
- Restoration point in time.
- security_group_ Sequence[str]ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- sync_mode str
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tag_lists Sequence[PostgresqlClone Db Instance Tag List Args] 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- autoRenew NumberFlag 
- Renewal Flag:
- dbInstance StringId 
- ID of the original instance to be cloned.
- period Number
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- specCode String
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage Number
- Instance storage capacity in GB.
- subnetId String
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- vpcId String
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId Number
- Campaign ID.
- backupSet StringId 
- Basic backup set ID.
- dbNode List<Property Map>Sets 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge StringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name String
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- postgresqlClone StringDb Instance Id 
- ID of the resource.
- projectId Number
- Project ID.
- recoveryTarget StringTime 
- Restoration point in time.
- securityGroup List<String>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- syncMode String
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists List<Property Map>
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
Outputs
All input properties are implicitly available as output properties. Additionally, the PostgresqlCloneDbInstance 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 PostgresqlCloneDbInstance Resource
Get an existing PostgresqlCloneDbInstance 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?: PostgresqlCloneDbInstanceState, opts?: CustomResourceOptions): PostgresqlCloneDbInstance@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        activity_id: Optional[float] = None,
        auto_renew_flag: Optional[float] = None,
        backup_set_id: Optional[str] = None,
        db_instance_id: Optional[str] = None,
        db_node_sets: Optional[Sequence[PostgresqlCloneDbInstanceDbNodeSetArgs]] = None,
        instance_charge_type: Optional[str] = None,
        name: Optional[str] = None,
        period: Optional[float] = None,
        postgresql_clone_db_instance_id: Optional[str] = None,
        project_id: Optional[float] = None,
        recovery_target_time: Optional[str] = None,
        security_group_ids: Optional[Sequence[str]] = None,
        spec_code: Optional[str] = None,
        storage: Optional[float] = None,
        subnet_id: Optional[str] = None,
        sync_mode: Optional[str] = None,
        tag_lists: Optional[Sequence[PostgresqlCloneDbInstanceTagListArgs]] = None,
        vpc_id: Optional[str] = None) -> PostgresqlCloneDbInstancefunc GetPostgresqlCloneDbInstance(ctx *Context, name string, id IDInput, state *PostgresqlCloneDbInstanceState, opts ...ResourceOption) (*PostgresqlCloneDbInstance, error)public static PostgresqlCloneDbInstance Get(string name, Input<string> id, PostgresqlCloneDbInstanceState? state, CustomResourceOptions? opts = null)public static PostgresqlCloneDbInstance get(String name, Output<String> id, PostgresqlCloneDbInstanceState state, CustomResourceOptions options)resources:  _:    type: tencentcloud:PostgresqlCloneDbInstance    get:      id: ${id}- 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.
- 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.
- ActivityId double
- Campaign ID.
- AutoRenew doubleFlag 
- Renewal Flag:
- BackupSet stringId 
- Basic backup set ID.
- DbInstance stringId 
- ID of the original instance to be cloned.
- DbNode List<PostgresqlSets Clone Db Instance Db Node Set> 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- InstanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- Name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- Period double
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- PostgresqlClone stringDb Instance Id 
- ID of the resource.
- ProjectId double
- Project ID.
- RecoveryTarget stringTime 
- Restoration point in time.
- SecurityGroup List<string>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- SpecCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- Storage double
- Instance storage capacity in GB.
- SubnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- SyncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- TagLists List<PostgresqlClone Db Instance Tag List> 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- VpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- ActivityId float64
- Campaign ID.
- AutoRenew float64Flag 
- Renewal Flag:
- BackupSet stringId 
- Basic backup set ID.
- DbInstance stringId 
- ID of the original instance to be cloned.
- DbNode []PostgresqlSets Clone Db Instance Db Node Set Args 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- InstanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- Name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- Period float64
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- PostgresqlClone stringDb Instance Id 
- ID of the resource.
- ProjectId float64
- Project ID.
- RecoveryTarget stringTime 
- Restoration point in time.
- SecurityGroup []stringIds 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- SpecCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- Storage float64
- Instance storage capacity in GB.
- SubnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- SyncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- TagLists []PostgresqlClone Db Instance Tag List Args 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- VpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId Double
- Campaign ID.
- autoRenew DoubleFlag 
- Renewal Flag:
- backupSet StringId 
- Basic backup set ID.
- dbInstance StringId 
- ID of the original instance to be cloned.
- dbNode List<PostgresqlSets Clone Db Instance Db Node Set> 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge StringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name String
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- period Double
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- postgresqlClone StringDb Instance Id 
- ID of the resource.
- projectId Double
- Project ID.
- recoveryTarget StringTime 
- Restoration point in time.
- securityGroup List<String>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- specCode String
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage Double
- Instance storage capacity in GB.
- subnetId String
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- syncMode String
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists List<PostgresqlClone Db Instance Tag List> 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- vpcId String
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId number
- Campaign ID.
- autoRenew numberFlag 
- Renewal Flag:
- backupSet stringId 
- Basic backup set ID.
- dbInstance stringId 
- ID of the original instance to be cloned.
- dbNode PostgresqlSets Clone Db Instance Db Node Set[] 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge stringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name string
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- period number
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- postgresqlClone stringDb Instance Id 
- ID of the resource.
- projectId number
- Project ID.
- recoveryTarget stringTime 
- Restoration point in time.
- securityGroup string[]Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- specCode string
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage number
- Instance storage capacity in GB.
- subnetId string
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- syncMode string
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists PostgresqlClone Db Instance Tag List[] 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- vpcId string
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activity_id float
- Campaign ID.
- auto_renew_ floatflag 
- Renewal Flag:
- backup_set_ strid 
- Basic backup set ID.
- db_instance_ strid 
- ID of the original instance to be cloned.
- db_node_ Sequence[Postgresqlsets Clone Db Instance Db Node Set Args] 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instance_charge_ strtype 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name str
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- period float
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- postgresql_clone_ strdb_ instance_ id 
- ID of the resource.
- project_id float
- Project ID.
- recovery_target_ strtime 
- Restoration point in time.
- security_group_ Sequence[str]ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- spec_code str
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage float
- Instance storage capacity in GB.
- subnet_id str
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- sync_mode str
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tag_lists Sequence[PostgresqlClone Db Instance Tag List Args] 
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- vpc_id str
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
- activityId Number
- Campaign ID.
- autoRenew NumberFlag 
- Renewal Flag:
- backupSet StringId 
- Basic backup set ID.
- dbInstance StringId 
- ID of the original instance to be cloned.
- dbNode List<Property Map>Sets 
- Deployment information of the instance node, which will display the information of each AZ when the instance node is deployed across multiple AZs.
The information of AZ can be obtained from the Zonefield in the return value of the DescribeZones API.
- instanceCharge StringType 
- Instance billing type, which currently supports: - PREPAID: Prepaid, i.e., monthly subscription
- POSTPAID_BY_HOUR: Pay-as-you-go, i.e., pay by consumption
 - Default value: PREPAID. 
- name String
- Name of the newly purchased instance, which can contain up to 60 letters, digits, or symbols (-_). If this parameter is not specified, "Unnamed" will be displayed by default.
- period Number
- Purchase duration, in months.- Prepaid: Supports 1,2,3,4,5,6,7,8,9,10,11,12,24, and36.
- Pay-as-you-go: Only supports 1.
 
- Prepaid: Supports 
- postgresqlClone StringDb Instance Id 
- ID of the resource.
- projectId Number
- Project ID.
- recoveryTarget StringTime 
- Restoration point in time.
- securityGroup List<String>Ids 
- Security group of the instance, which can be obtained from the sgldfield in the return value of the DescribeSecurityGroups API. If this parameter is not specified, the default security group will be bound.
- specCode String
- Purchasable code, which can be obtained from the SpecCodefield in the return value of the DescribeClasses API.
- storage Number
- Instance storage capacity in GB.
- subnetId String
- VPC subnet ID in the format of subnet-xxxxxxxx, which can be obtained in the console or from theunSubnetIdfield in the return value of the DescribeSubnets API.
- syncMode String
- Primary-standby sync mode, which supports: Semi-sync: Semi-sync Async: Asynchronous Default value for the primary instance: Semi-sync Default value for the read-only instance: Async.
- tagLists List<Property Map>
- The information of tags to be bound with the instance, which is left empty by default. This parameter can be obtained from the Tagsfield in the return value of the DescribeTags API.
- vpcId String
- VPC ID in the format of vpc-xxxxxxx, which can be obtained in the console or from theunVpcIdfield in the return value of the DescribeVpcEx API.
Supporting Types
PostgresqlCloneDbInstanceDbNodeSet, PostgresqlCloneDbInstanceDbNodeSetArgs              
- Role string
- Node type. Valid values:
Primary;Standby.
- Zone string
- AZ where the node resides, such as ap-guangzhou-1.
- DedicatedCluster stringId 
- Dedicated cluster ID.
- Role string
- Node type. Valid values:
Primary;Standby.
- Zone string
- AZ where the node resides, such as ap-guangzhou-1.
- DedicatedCluster stringId 
- Dedicated cluster ID.
- role String
- Node type. Valid values:
Primary;Standby.
- zone String
- AZ where the node resides, such as ap-guangzhou-1.
- dedicatedCluster StringId 
- Dedicated cluster ID.
- role string
- Node type. Valid values:
Primary;Standby.
- zone string
- AZ where the node resides, such as ap-guangzhou-1.
- dedicatedCluster stringId 
- Dedicated cluster ID.
- role str
- Node type. Valid values:
Primary;Standby.
- zone str
- AZ where the node resides, such as ap-guangzhou-1.
- dedicated_cluster_ strid 
- Dedicated cluster ID.
- role String
- Node type. Valid values:
Primary;Standby.
- zone String
- AZ where the node resides, such as ap-guangzhou-1.
- dedicatedCluster StringId 
- Dedicated cluster ID.
PostgresqlCloneDbInstanceTagList, PostgresqlCloneDbInstanceTagListArgs            
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the tencentcloudTerraform Provider.