volcengine.mongodb.Instance
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@volcengine/pulumi";
const foo = new volcengine.mongodb.Instance("foo", {
    chargeType: "PostPaid",
    dbEngineVersion: "MongoDB_4_0",
    instanceName: "mongo-replica-be9995d32e4a",
    instanceType: "ReplicaSet",
    nodeSpec: "mongo.2c4g",
    projectName: "default",
    storageSpaceGb: 20,
    subnetId: "subnet-rrx4ns6abw1sv0x57wq6h47",
    superAccountPassword: "******",
    tags: [{
        key: "k1",
        value: "v1",
    }],
    zoneId: "cn-beijing-a",
});
import pulumi
import pulumi_volcengine as volcengine
foo = volcengine.mongodb.Instance("foo",
    charge_type="PostPaid",
    db_engine_version="MongoDB_4_0",
    instance_name="mongo-replica-be9995d32e4a",
    instance_type="ReplicaSet",
    node_spec="mongo.2c4g",
    project_name="default",
    storage_space_gb=20,
    subnet_id="subnet-rrx4ns6abw1sv0x57wq6h47",
    super_account_password="******",
    tags=[volcengine.mongodb.InstanceTagArgs(
        key="k1",
        value="v1",
    )],
    zone_id="cn-beijing-a")
package main
import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/mongodb"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := mongodb.NewInstance(ctx, "foo", &mongodb.InstanceArgs{
			ChargeType:           pulumi.String("PostPaid"),
			DbEngineVersion:      pulumi.String("MongoDB_4_0"),
			InstanceName:         pulumi.String("mongo-replica-be9995d32e4a"),
			InstanceType:         pulumi.String("ReplicaSet"),
			NodeSpec:             pulumi.String("mongo.2c4g"),
			ProjectName:          pulumi.String("default"),
			StorageSpaceGb:       pulumi.Int(20),
			SubnetId:             pulumi.String("subnet-rrx4ns6abw1sv0x57wq6h47"),
			SuperAccountPassword: pulumi.String("******"),
			Tags: mongodb.InstanceTagArray{
				&mongodb.InstanceTagArgs{
					Key:   pulumi.String("k1"),
					Value: pulumi.String("v1"),
				},
			},
			ZoneId: pulumi.String("cn-beijing-a"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;
return await Deployment.RunAsync(() => 
{
    var foo = new Volcengine.Mongodb.Instance("foo", new()
    {
        ChargeType = "PostPaid",
        DbEngineVersion = "MongoDB_4_0",
        InstanceName = "mongo-replica-be9995d32e4a",
        InstanceType = "ReplicaSet",
        NodeSpec = "mongo.2c4g",
        ProjectName = "default",
        StorageSpaceGb = 20,
        SubnetId = "subnet-rrx4ns6abw1sv0x57wq6h47",
        SuperAccountPassword = "******",
        Tags = new[]
        {
            new Volcengine.Mongodb.Inputs.InstanceTagArgs
            {
                Key = "k1",
                Value = "v1",
            },
        },
        ZoneId = "cn-beijing-a",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.mongodb.Instance;
import com.pulumi.volcengine.mongodb.InstanceArgs;
import com.pulumi.volcengine.mongodb.inputs.InstanceTagArgs;
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 foo = new Instance("foo", InstanceArgs.builder()        
            .chargeType("PostPaid")
            .dbEngineVersion("MongoDB_4_0")
            .instanceName("mongo-replica-be9995d32e4a")
            .instanceType("ReplicaSet")
            .nodeSpec("mongo.2c4g")
            .projectName("default")
            .storageSpaceGb(20)
            .subnetId("subnet-rrx4ns6abw1sv0x57wq6h47")
            .superAccountPassword("******")
            .tags(InstanceTagArgs.builder()
                .key("k1")
                .value("v1")
                .build())
            .zoneId("cn-beijing-a")
            .build());
    }
}
resources:
  foo:
    type: volcengine:mongodb:Instance
    properties:
      chargeType: PostPaid
      dbEngineVersion: MongoDB_4_0
      instanceName: mongo-replica-be9995d32e4a
      instanceType: ReplicaSet
      nodeSpec: mongo.2c4g
      projectName: default
      # mongos_node_spec="mongo.mongos.2c4g"
      #     //    mongos_node_number = 3
      #     //    shard_number=3
      storageSpaceGb: 20
      subnetId: subnet-rrx4ns6abw1sv0x57wq6h47
      superAccountPassword: '******'
      tags:
        - key: k1
          value: v1
      zoneId: cn-beijing-a
Create Instance Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Instance(name: string, args: InstanceArgs, opts?: CustomResourceOptions);@overload
def Instance(resource_name: str,
             args: InstanceArgs,
             opts: Optional[ResourceOptions] = None)
@overload
def Instance(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             node_spec: Optional[str] = None,
             subnet_id: Optional[str] = None,
             storage_space_gb: Optional[int] = None,
             instance_type: Optional[str] = None,
             project_name: Optional[str] = None,
             mongos_node_number: Optional[int] = None,
             mongos_node_spec: Optional[str] = None,
             instance_name: Optional[str] = None,
             period: Optional[int] = None,
             period_unit: Optional[str] = None,
             auto_renew: Optional[bool] = None,
             shard_number: Optional[int] = None,
             db_engine_version: Optional[str] = None,
             charge_type: Optional[str] = None,
             super_account_password: Optional[str] = None,
             tags: Optional[Sequence[InstanceTagArgs]] = None,
             vpc_id: Optional[str] = None,
             zone_id: Optional[str] = None)func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
public Instance(String name, InstanceArgs args)
public Instance(String name, InstanceArgs args, CustomResourceOptions options)
type: volcengine:mongodb:Instance
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 InstanceArgs
- 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 InstanceArgs
- 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 InstanceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var exampleinstanceResourceResourceFromMongodbinstance = new Volcengine.Mongodb.Instance("exampleinstanceResourceResourceFromMongodbinstance", new()
{
    NodeSpec = "string",
    SubnetId = "string",
    StorageSpaceGb = 0,
    InstanceType = "string",
    ProjectName = "string",
    MongosNodeNumber = 0,
    MongosNodeSpec = "string",
    InstanceName = "string",
    Period = 0,
    PeriodUnit = "string",
    AutoRenew = false,
    ShardNumber = 0,
    DbEngineVersion = "string",
    ChargeType = "string",
    SuperAccountPassword = "string",
    Tags = new[]
    {
        new Volcengine.Mongodb.Inputs.InstanceTagArgs
        {
            Key = "string",
            Value = "string",
        },
    },
    VpcId = "string",
    ZoneId = "string",
});
example, err := mongodb.NewInstance(ctx, "exampleinstanceResourceResourceFromMongodbinstance", &mongodb.InstanceArgs{
	NodeSpec:             pulumi.String("string"),
	SubnetId:             pulumi.String("string"),
	StorageSpaceGb:       pulumi.Int(0),
	InstanceType:         pulumi.String("string"),
	ProjectName:          pulumi.String("string"),
	MongosNodeNumber:     pulumi.Int(0),
	MongosNodeSpec:       pulumi.String("string"),
	InstanceName:         pulumi.String("string"),
	Period:               pulumi.Int(0),
	PeriodUnit:           pulumi.String("string"),
	AutoRenew:            pulumi.Bool(false),
	ShardNumber:          pulumi.Int(0),
	DbEngineVersion:      pulumi.String("string"),
	ChargeType:           pulumi.String("string"),
	SuperAccountPassword: pulumi.String("string"),
	Tags: mongodb.InstanceTagArray{
		&mongodb.InstanceTagArgs{
			Key:   pulumi.String("string"),
			Value: pulumi.String("string"),
		},
	},
	VpcId:  pulumi.String("string"),
	ZoneId: pulumi.String("string"),
})
var exampleinstanceResourceResourceFromMongodbinstance = new Instance("exampleinstanceResourceResourceFromMongodbinstance", InstanceArgs.builder()
    .nodeSpec("string")
    .subnetId("string")
    .storageSpaceGb(0)
    .instanceType("string")
    .projectName("string")
    .mongosNodeNumber(0)
    .mongosNodeSpec("string")
    .instanceName("string")
    .period(0)
    .periodUnit("string")
    .autoRenew(false)
    .shardNumber(0)
    .dbEngineVersion("string")
    .chargeType("string")
    .superAccountPassword("string")
    .tags(InstanceTagArgs.builder()
        .key("string")
        .value("string")
        .build())
    .vpcId("string")
    .zoneId("string")
    .build());
exampleinstance_resource_resource_from_mongodbinstance = volcengine.mongodb.Instance("exampleinstanceResourceResourceFromMongodbinstance",
    node_spec="string",
    subnet_id="string",
    storage_space_gb=0,
    instance_type="string",
    project_name="string",
    mongos_node_number=0,
    mongos_node_spec="string",
    instance_name="string",
    period=0,
    period_unit="string",
    auto_renew=False,
    shard_number=0,
    db_engine_version="string",
    charge_type="string",
    super_account_password="string",
    tags=[{
        "key": "string",
        "value": "string",
    }],
    vpc_id="string",
    zone_id="string")
const exampleinstanceResourceResourceFromMongodbinstance = new volcengine.mongodb.Instance("exampleinstanceResourceResourceFromMongodbinstance", {
    nodeSpec: "string",
    subnetId: "string",
    storageSpaceGb: 0,
    instanceType: "string",
    projectName: "string",
    mongosNodeNumber: 0,
    mongosNodeSpec: "string",
    instanceName: "string",
    period: 0,
    periodUnit: "string",
    autoRenew: false,
    shardNumber: 0,
    dbEngineVersion: "string",
    chargeType: "string",
    superAccountPassword: "string",
    tags: [{
        key: "string",
        value: "string",
    }],
    vpcId: "string",
    zoneId: "string",
});
type: volcengine:mongodb:Instance
properties:
    autoRenew: false
    chargeType: string
    dbEngineVersion: string
    instanceName: string
    instanceType: string
    mongosNodeNumber: 0
    mongosNodeSpec: string
    nodeSpec: string
    period: 0
    periodUnit: string
    projectName: string
    shardNumber: 0
    storageSpaceGb: 0
    subnetId: string
    superAccountPassword: string
    tags:
        - key: string
          value: string
    vpcId: string
    zoneId: string
Instance 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 Instance resource accepts the following input properties:
- NodeSpec string
- The spec of node.
- StorageSpace intGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- SubnetId string
- The subnet id of instance.
- AutoRenew bool
- Whether to enable automatic renewal.
- ChargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- DbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- InstanceName string
- The instance name.
- InstanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- MongosNode intNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- MongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- Period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- PeriodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- ProjectName string
- The project name to which the instance belongs.
- int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- SuperAccount stringPassword 
- The password of database account.
- 
List<InstanceTag> 
- Tags.
- VpcId string
- The vpc ID.
- ZoneId string
- The zone ID of instance.
- NodeSpec string
- The spec of node.
- StorageSpace intGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- SubnetId string
- The subnet id of instance.
- AutoRenew bool
- Whether to enable automatic renewal.
- ChargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- DbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- InstanceName string
- The instance name.
- InstanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- MongosNode intNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- MongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- Period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- PeriodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- ProjectName string
- The project name to which the instance belongs.
- int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- SuperAccount stringPassword 
- The password of database account.
- 
[]InstanceTag Args 
- Tags.
- VpcId string
- The vpc ID.
- ZoneId string
- The zone ID of instance.
- nodeSpec String
- The spec of node.
- storageSpace IntegerGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId String
- The subnet id of instance.
- autoRenew Boolean
- Whether to enable automatic renewal.
- chargeType String
- The charge type of instance, valid value contains PrepaidorPostPaid.
- dbEngine StringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName String
- The instance name.
- instanceType String
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongosNode IntegerNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode StringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- period Integer
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit String
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName String
- The project name to which the instance belongs.
- Integer
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- superAccount StringPassword 
- The password of database account.
- 
List<InstanceTag> 
- Tags.
- vpcId String
- The vpc ID.
- zoneId String
- The zone ID of instance.
- nodeSpec string
- The spec of node.
- storageSpace numberGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId string
- The subnet id of instance.
- autoRenew boolean
- Whether to enable automatic renewal.
- chargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- dbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName string
- The instance name.
- instanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongosNode numberNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- period number
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName string
- The project name to which the instance belongs.
- number
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- superAccount stringPassword 
- The password of database account.
- 
InstanceTag[] 
- Tags.
- vpcId string
- The vpc ID.
- zoneId string
- The zone ID of instance.
- node_spec str
- The spec of node.
- storage_space_ intgb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnet_id str
- The subnet id of instance.
- auto_renew bool
- Whether to enable automatic renewal.
- charge_type str
- The charge type of instance, valid value contains PrepaidorPostPaid.
- db_engine_ strversion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instance_name str
- The instance name.
- instance_type str
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongos_node_ intnumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongos_node_ strspec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- period_unit str
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- project_name str
- The project name to which the instance belongs.
- int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- super_account_ strpassword 
- The password of database account.
- 
Sequence[InstanceTag Args] 
- Tags.
- vpc_id str
- The vpc ID.
- zone_id str
- The zone ID of instance.
- nodeSpec String
- The spec of node.
- storageSpace NumberGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId String
- The subnet id of instance.
- autoRenew Boolean
- Whether to enable automatic renewal.
- chargeType String
- The charge type of instance, valid value contains PrepaidorPostPaid.
- dbEngine StringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName String
- The instance name.
- instanceType String
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongosNode NumberNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode StringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- period Number
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit String
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName String
- The project name to which the instance belongs.
- Number
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- superAccount StringPassword 
- The password of database account.
- List<Property Map>
- Tags.
- vpcId String
- The vpc ID.
- zoneId String
- The zone ID of instance.
Outputs
All input properties are implicitly available as output properties. Additionally, the Instance resource produces the following output properties:
- ConfigServers stringId 
- The config servers id of the ShardedCluster instance.
- Id string
- The provider-assigned unique ID for this managed resource.
- Mongos
List<InstanceMongo> 
- The mongos information of the ShardedCluster instance.
- MongosId string
- The mongos id of the ShardedCluster instance.
- 
List<InstanceShard> 
- The shards information of the ShardedCluster instance.
- ConfigServers stringId 
- The config servers id of the ShardedCluster instance.
- Id string
- The provider-assigned unique ID for this managed resource.
- Mongos
[]InstanceMongo 
- The mongos information of the ShardedCluster instance.
- MongosId string
- The mongos id of the ShardedCluster instance.
- 
[]InstanceShard 
- The shards information of the ShardedCluster instance.
- configServers StringId 
- The config servers id of the ShardedCluster instance.
- id String
- The provider-assigned unique ID for this managed resource.
- mongos
List<InstanceMongo> 
- The mongos information of the ShardedCluster instance.
- mongosId String
- The mongos id of the ShardedCluster instance.
- 
List<InstanceShard> 
- The shards information of the ShardedCluster instance.
- configServers stringId 
- The config servers id of the ShardedCluster instance.
- id string
- The provider-assigned unique ID for this managed resource.
- mongos
InstanceMongo[] 
- The mongos information of the ShardedCluster instance.
- mongosId string
- The mongos id of the ShardedCluster instance.
- 
InstanceShard[] 
- The shards information of the ShardedCluster instance.
- config_servers_ strid 
- The config servers id of the ShardedCluster instance.
- id str
- The provider-assigned unique ID for this managed resource.
- mongos
Sequence[InstanceMongo] 
- The mongos information of the ShardedCluster instance.
- mongos_id str
- The mongos id of the ShardedCluster instance.
- 
Sequence[InstanceShard] 
- The shards information of the ShardedCluster instance.
- configServers StringId 
- The config servers id of the ShardedCluster instance.
- id String
- The provider-assigned unique ID for this managed resource.
- mongos List<Property Map>
- The mongos information of the ShardedCluster instance.
- mongosId String
- The mongos id of the ShardedCluster instance.
- List<Property Map>
- The shards information of the ShardedCluster instance.
Look up Existing Instance Resource
Get an existing Instance 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?: InstanceState, opts?: CustomResourceOptions): Instance@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        auto_renew: Optional[bool] = None,
        charge_type: Optional[str] = None,
        config_servers_id: Optional[str] = None,
        db_engine_version: Optional[str] = None,
        instance_name: Optional[str] = None,
        instance_type: Optional[str] = None,
        mongos: Optional[Sequence[InstanceMongoArgs]] = None,
        mongos_id: Optional[str] = None,
        mongos_node_number: Optional[int] = None,
        mongos_node_spec: Optional[str] = None,
        node_spec: Optional[str] = None,
        period: Optional[int] = None,
        period_unit: Optional[str] = None,
        project_name: Optional[str] = None,
        shard_number: Optional[int] = None,
        shards: Optional[Sequence[InstanceShardArgs]] = None,
        storage_space_gb: Optional[int] = None,
        subnet_id: Optional[str] = None,
        super_account_password: Optional[str] = None,
        tags: Optional[Sequence[InstanceTagArgs]] = None,
        vpc_id: Optional[str] = None,
        zone_id: Optional[str] = None) -> Instancefunc GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)resources:  _:    type: volcengine:mongodb:Instance    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.
- AutoRenew bool
- Whether to enable automatic renewal.
- ChargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- ConfigServers stringId 
- The config servers id of the ShardedCluster instance.
- DbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- InstanceName string
- The instance name.
- InstanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- Mongos
List<InstanceMongo> 
- The mongos information of the ShardedCluster instance.
- MongosId string
- The mongos id of the ShardedCluster instance.
- MongosNode intNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- MongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- NodeSpec string
- The spec of node.
- Period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- PeriodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- ProjectName string
- The project name to which the instance belongs.
- ShardNumber int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- Shards
List<InstanceShard> 
- The shards information of the ShardedCluster instance.
- StorageSpace intGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- SubnetId string
- The subnet id of instance.
- SuperAccount stringPassword 
- The password of database account.
- 
List<InstanceTag> 
- Tags.
- VpcId string
- The vpc ID.
- ZoneId string
- The zone ID of instance.
- AutoRenew bool
- Whether to enable automatic renewal.
- ChargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- ConfigServers stringId 
- The config servers id of the ShardedCluster instance.
- DbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- InstanceName string
- The instance name.
- InstanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- Mongos
[]InstanceMongo Args 
- The mongos information of the ShardedCluster instance.
- MongosId string
- The mongos id of the ShardedCluster instance.
- MongosNode intNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- MongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- NodeSpec string
- The spec of node.
- Period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- PeriodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- ProjectName string
- The project name to which the instance belongs.
- ShardNumber int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- Shards
[]InstanceShard Args 
- The shards information of the ShardedCluster instance.
- StorageSpace intGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- SubnetId string
- The subnet id of instance.
- SuperAccount stringPassword 
- The password of database account.
- 
[]InstanceTag Args 
- Tags.
- VpcId string
- The vpc ID.
- ZoneId string
- The zone ID of instance.
- autoRenew Boolean
- Whether to enable automatic renewal.
- chargeType String
- The charge type of instance, valid value contains PrepaidorPostPaid.
- configServers StringId 
- The config servers id of the ShardedCluster instance.
- dbEngine StringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName String
- The instance name.
- instanceType String
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongos
List<InstanceMongo> 
- The mongos information of the ShardedCluster instance.
- mongosId String
- The mongos id of the ShardedCluster instance.
- mongosNode IntegerNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode StringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- nodeSpec String
- The spec of node.
- period Integer
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit String
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName String
- The project name to which the instance belongs.
- shardNumber Integer
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- shards
List<InstanceShard> 
- The shards information of the ShardedCluster instance.
- storageSpace IntegerGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId String
- The subnet id of instance.
- superAccount StringPassword 
- The password of database account.
- 
List<InstanceTag> 
- Tags.
- vpcId String
- The vpc ID.
- zoneId String
- The zone ID of instance.
- autoRenew boolean
- Whether to enable automatic renewal.
- chargeType string
- The charge type of instance, valid value contains PrepaidorPostPaid.
- configServers stringId 
- The config servers id of the ShardedCluster instance.
- dbEngine stringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName string
- The instance name.
- instanceType string
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongos
InstanceMongo[] 
- The mongos information of the ShardedCluster instance.
- mongosId string
- The mongos id of the ShardedCluster instance.
- mongosNode numberNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode stringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- nodeSpec string
- The spec of node.
- period number
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit string
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName string
- The project name to which the instance belongs.
- shardNumber number
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- shards
InstanceShard[] 
- The shards information of the ShardedCluster instance.
- storageSpace numberGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId string
- The subnet id of instance.
- superAccount stringPassword 
- The password of database account.
- 
InstanceTag[] 
- Tags.
- vpcId string
- The vpc ID.
- zoneId string
- The zone ID of instance.
- auto_renew bool
- Whether to enable automatic renewal.
- charge_type str
- The charge type of instance, valid value contains PrepaidorPostPaid.
- config_servers_ strid 
- The config servers id of the ShardedCluster instance.
- db_engine_ strversion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instance_name str
- The instance name.
- instance_type str
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongos
Sequence[InstanceMongo Args] 
- The mongos information of the ShardedCluster instance.
- mongos_id str
- The mongos id of the ShardedCluster instance.
- mongos_node_ intnumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongos_node_ strspec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- node_spec str
- The spec of node.
- period int
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- period_unit str
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- project_name str
- The project name to which the instance belongs.
- shard_number int
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- shards
Sequence[InstanceShard Args] 
- The shards information of the ShardedCluster instance.
- storage_space_ intgb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnet_id str
- The subnet id of instance.
- super_account_ strpassword 
- The password of database account.
- 
Sequence[InstanceTag Args] 
- Tags.
- vpc_id str
- The vpc ID.
- zone_id str
- The zone ID of instance.
- autoRenew Boolean
- Whether to enable automatic renewal.
- chargeType String
- The charge type of instance, valid value contains PrepaidorPostPaid.
- configServers StringId 
- The config servers id of the ShardedCluster instance.
- dbEngine StringVersion 
- The version of db engine, valid value contains MongoDB_4_0,MongoDB_5_0.
- instanceName String
- The instance name.
- instanceType String
- The type of instance,the valid value contains ReplicaSetorShardedCluster.
- mongos List<Property Map>
- The mongos information of the ShardedCluster instance.
- mongosId String
- The mongos id of the ShardedCluster instance.
- mongosNode NumberNumber 
- The mongos node number of shard cluster,value range is 2~23, this parameter is required whenInstanceTypeisShardedCluster.
- mongosNode StringSpec 
- The mongos node spec of shard cluster, this parameter is required when InstanceTypeisShardedCluster.
- nodeSpec String
- The spec of node.
- period Number
- The instance purchase duration,the value range is 1~3whenPeriodUtilisYear, the value range is1~9whenPeriodUtilisMonth, this parameter is required whenChargeTypeisPrepaid.
- periodUnit String
- The period unit,valid value contains YearorMonth, this parameter is required whenChargeTypeisPrepaid.
- projectName String
- The project name to which the instance belongs.
- shardNumber Number
- The number of shards in shard cluster,value range is 2~32, this parameter is required whenInstanceTypeisShardedCluster.
- shards List<Property Map>
- The shards information of the ShardedCluster instance.
- storageSpace NumberGb 
- The total storage space of a replica set instance, or the storage space of a single shard in a sharded cluster, in GiB.
- subnetId String
- The subnet id of instance.
- superAccount StringPassword 
- The password of database account.
- List<Property Map>
- Tags.
- vpcId String
- The vpc ID.
- zoneId String
- The zone ID of instance.
Supporting Types
InstanceMongo, InstanceMongoArgs    
- MongosNode stringId 
- The mongos node ID.
- NodeSpec string
- The spec of node.
- NodeStatus string
- The node status.
- MongosNode stringId 
- The mongos node ID.
- NodeSpec string
- The spec of node.
- NodeStatus string
- The node status.
- mongosNode StringId 
- The mongos node ID.
- nodeSpec String
- The spec of node.
- nodeStatus String
- The node status.
- mongosNode stringId 
- The mongos node ID.
- nodeSpec string
- The spec of node.
- nodeStatus string
- The node status.
- mongos_node_ strid 
- The mongos node ID.
- node_spec str
- The spec of node.
- node_status str
- The node status.
- mongosNode StringId 
- The mongos node ID.
- nodeSpec String
- The spec of node.
- nodeStatus String
- The node status.
InstanceShard, InstanceShardArgs    
- string
- The shard id.
- string
- The shard id.
- String
- The shard id.
- string
- The shard id.
- str
- The shard id.
- String
- The shard id.
InstanceTag, InstanceTagArgs    
Import
mongodb instance can be imported using the id, e.g.
$ pulumi import volcengine:mongodb/instance:Instance default mongo-replica-e405f8e2****
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- volcengine volcengine/pulumi-volcengine
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the volcengineTerraform Provider.