volcengine.mongodb.Account
Explore with Pulumi AI
Provides a resource to manage mongodb account
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";
import * as volcengine from "@volcengine/pulumi";
const fooZones = volcengine.ecs.Zones({});
const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
vpcName: "acc-test-vpc",
cidrBlock: "172.16.0.0/16",
});
const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
subnetName: "acc-test-subnet",
cidrBlock: "172.16.0.0/24",
zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
vpcId: fooVpc.id,
});
const fooInstance = new volcengine.mongodb.Instance("fooInstance", {
zoneIds: [fooZones.then(fooZones => fooZones.zones?.[0]?.id)],
dbEngineVersion: "MongoDB_4_0",
instanceType: "ReplicaSet",
nodeSpec: "mongo.2c4g",
storageSpaceGb: 20,
subnetId: fooSubnet.id,
instanceName: "acc-test-mongodb-replica",
chargeType: "PostPaid",
superAccountPassword: "93f0cb0614Aab12",
projectName: "default",
tags: [{
key: "k1",
value: "v1",
}],
});
const fooAccount = new volcengine.mongodb.Account("fooAccount", {
instanceId: fooInstance.id,
accountName: "acc-test-mongodb-account",
authDb: "admin",
accountPassword: "93f0cb0614Aab12",
accountDesc: "acc-test",
accountPrivileges: [
{
dbName: "admin",
roleNames: [
"userAdmin",
"clusterMonitor",
],
},
{
dbName: "config",
roleNames: ["read"],
},
{
dbName: "local",
roleNames: ["read"],
},
],
});
import pulumi
import pulumi_volcengine as volcengine
foo_zones = volcengine.ecs.zones()
foo_vpc = volcengine.vpc.Vpc("fooVpc",
vpc_name="acc-test-vpc",
cidr_block="172.16.0.0/16")
foo_subnet = volcengine.vpc.Subnet("fooSubnet",
subnet_name="acc-test-subnet",
cidr_block="172.16.0.0/24",
zone_id=foo_zones.zones[0].id,
vpc_id=foo_vpc.id)
foo_instance = volcengine.mongodb.Instance("fooInstance",
zone_ids=[foo_zones.zones[0].id],
db_engine_version="MongoDB_4_0",
instance_type="ReplicaSet",
node_spec="mongo.2c4g",
storage_space_gb=20,
subnet_id=foo_subnet.id,
instance_name="acc-test-mongodb-replica",
charge_type="PostPaid",
super_account_password="93f0cb0614Aab12",
project_name="default",
tags=[volcengine.mongodb.InstanceTagArgs(
key="k1",
value="v1",
)])
foo_account = volcengine.mongodb.Account("fooAccount",
instance_id=foo_instance.id,
account_name="acc-test-mongodb-account",
auth_db="admin",
account_password="93f0cb0614Aab12",
account_desc="acc-test",
account_privileges=[
volcengine.mongodb.AccountAccountPrivilegeArgs(
db_name="admin",
role_names=[
"userAdmin",
"clusterMonitor",
],
),
volcengine.mongodb.AccountAccountPrivilegeArgs(
db_name="config",
role_names=["read"],
),
volcengine.mongodb.AccountAccountPrivilegeArgs(
db_name="local",
role_names=["read"],
),
])
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/mongodb"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
fooZones, err := ecs.Zones(ctx, nil, nil)
if err != nil {
return err
}
fooVpc, err := vpc.NewVpc(ctx, "fooVpc", &vpc.VpcArgs{
VpcName: pulumi.String("acc-test-vpc"),
CidrBlock: pulumi.String("172.16.0.0/16"),
})
if err != nil {
return err
}
fooSubnet, err := vpc.NewSubnet(ctx, "fooSubnet", &vpc.SubnetArgs{
SubnetName: pulumi.String("acc-test-subnet"),
CidrBlock: pulumi.String("172.16.0.0/24"),
ZoneId: pulumi.String(fooZones.Zones[0].Id),
VpcId: fooVpc.ID(),
})
if err != nil {
return err
}
fooInstance, err := mongodb.NewInstance(ctx, "fooInstance", &mongodb.InstanceArgs{
ZoneIds: pulumi.StringArray{
pulumi.String(fooZones.Zones[0].Id),
},
DbEngineVersion: pulumi.String("MongoDB_4_0"),
InstanceType: pulumi.String("ReplicaSet"),
NodeSpec: pulumi.String("mongo.2c4g"),
StorageSpaceGb: pulumi.Int(20),
SubnetId: fooSubnet.ID(),
InstanceName: pulumi.String("acc-test-mongodb-replica"),
ChargeType: pulumi.String("PostPaid"),
SuperAccountPassword: pulumi.String("93f0cb0614Aab12"),
ProjectName: pulumi.String("default"),
Tags: mongodb.InstanceTagArray{
&mongodb.InstanceTagArgs{
Key: pulumi.String("k1"),
Value: pulumi.String("v1"),
},
},
})
if err != nil {
return err
}
_, err = mongodb.NewAccount(ctx, "fooAccount", &mongodb.AccountArgs{
InstanceId: fooInstance.ID(),
AccountName: pulumi.String("acc-test-mongodb-account"),
AuthDb: pulumi.String("admin"),
AccountPassword: pulumi.String("93f0cb0614Aab12"),
AccountDesc: pulumi.String("acc-test"),
AccountPrivileges: mongodb.AccountAccountPrivilegeArray{
&mongodb.AccountAccountPrivilegeArgs{
DbName: pulumi.String("admin"),
RoleNames: pulumi.StringArray{
pulumi.String("userAdmin"),
pulumi.String("clusterMonitor"),
},
},
&mongodb.AccountAccountPrivilegeArgs{
DbName: pulumi.String("config"),
RoleNames: pulumi.StringArray{
pulumi.String("read"),
},
},
&mongodb.AccountAccountPrivilegeArgs{
DbName: pulumi.String("local"),
RoleNames: pulumi.StringArray{
pulumi.String("read"),
},
},
},
})
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 fooZones = Volcengine.Ecs.Zones.Invoke();
var fooVpc = new Volcengine.Vpc.Vpc("fooVpc", new()
{
VpcName = "acc-test-vpc",
CidrBlock = "172.16.0.0/16",
});
var fooSubnet = new Volcengine.Vpc.Subnet("fooSubnet", new()
{
SubnetName = "acc-test-subnet",
CidrBlock = "172.16.0.0/24",
ZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
VpcId = fooVpc.Id,
});
var fooInstance = new Volcengine.Mongodb.Instance("fooInstance", new()
{
ZoneIds = new[]
{
fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
},
DbEngineVersion = "MongoDB_4_0",
InstanceType = "ReplicaSet",
NodeSpec = "mongo.2c4g",
StorageSpaceGb = 20,
SubnetId = fooSubnet.Id,
InstanceName = "acc-test-mongodb-replica",
ChargeType = "PostPaid",
SuperAccountPassword = "93f0cb0614Aab12",
ProjectName = "default",
Tags = new[]
{
new Volcengine.Mongodb.Inputs.InstanceTagArgs
{
Key = "k1",
Value = "v1",
},
},
});
var fooAccount = new Volcengine.Mongodb.Account("fooAccount", new()
{
InstanceId = fooInstance.Id,
AccountName = "acc-test-mongodb-account",
AuthDb = "admin",
AccountPassword = "93f0cb0614Aab12",
AccountDesc = "acc-test",
AccountPrivileges = new[]
{
new Volcengine.Mongodb.Inputs.AccountAccountPrivilegeArgs
{
DbName = "admin",
RoleNames = new[]
{
"userAdmin",
"clusterMonitor",
},
},
new Volcengine.Mongodb.Inputs.AccountAccountPrivilegeArgs
{
DbName = "config",
RoleNames = new[]
{
"read",
},
},
new Volcengine.Mongodb.Inputs.AccountAccountPrivilegeArgs
{
DbName = "local",
RoleNames = new[]
{
"read",
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.ecs.EcsFunctions;
import com.pulumi.volcengine.ecs.inputs.ZonesArgs;
import com.pulumi.volcengine.vpc.Vpc;
import com.pulumi.volcengine.vpc.VpcArgs;
import com.pulumi.volcengine.vpc.Subnet;
import com.pulumi.volcengine.vpc.SubnetArgs;
import com.pulumi.volcengine.mongodb.Instance;
import com.pulumi.volcengine.mongodb.InstanceArgs;
import com.pulumi.volcengine.mongodb.inputs.InstanceTagArgs;
import com.pulumi.volcengine.mongodb.Account;
import com.pulumi.volcengine.mongodb.AccountArgs;
import com.pulumi.volcengine.mongodb.inputs.AccountAccountPrivilegeArgs;
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 fooZones = EcsFunctions.Zones();
var fooVpc = new Vpc("fooVpc", VpcArgs.builder()
.vpcName("acc-test-vpc")
.cidrBlock("172.16.0.0/16")
.build());
var fooSubnet = new Subnet("fooSubnet", SubnetArgs.builder()
.subnetName("acc-test-subnet")
.cidrBlock("172.16.0.0/24")
.zoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
.vpcId(fooVpc.id())
.build());
var fooInstance = new Instance("fooInstance", InstanceArgs.builder()
.zoneIds(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
.dbEngineVersion("MongoDB_4_0")
.instanceType("ReplicaSet")
.nodeSpec("mongo.2c4g")
.storageSpaceGb(20)
.subnetId(fooSubnet.id())
.instanceName("acc-test-mongodb-replica")
.chargeType("PostPaid")
.superAccountPassword("93f0cb0614Aab12")
.projectName("default")
.tags(InstanceTagArgs.builder()
.key("k1")
.value("v1")
.build())
.build());
var fooAccount = new Account("fooAccount", AccountArgs.builder()
.instanceId(fooInstance.id())
.accountName("acc-test-mongodb-account")
.authDb("admin")
.accountPassword("93f0cb0614Aab12")
.accountDesc("acc-test")
.accountPrivileges(
AccountAccountPrivilegeArgs.builder()
.dbName("admin")
.roleNames(
"userAdmin",
"clusterMonitor")
.build(),
AccountAccountPrivilegeArgs.builder()
.dbName("config")
.roleNames("read")
.build(),
AccountAccountPrivilegeArgs.builder()
.dbName("local")
.roleNames("read")
.build())
.build());
}
}
resources:
fooVpc:
type: volcengine:vpc:Vpc
properties:
vpcName: acc-test-vpc
cidrBlock: 172.16.0.0/16
fooSubnet:
type: volcengine:vpc:Subnet
properties:
subnetName: acc-test-subnet
cidrBlock: 172.16.0.0/24
zoneId: ${fooZones.zones[0].id}
vpcId: ${fooVpc.id}
fooInstance:
type: volcengine:mongodb:Instance
properties:
zoneIds:
- ${fooZones.zones[0].id}
dbEngineVersion: MongoDB_4_0
instanceType: ReplicaSet
nodeSpec: mongo.2c4g
storageSpaceGb: 20
subnetId: ${fooSubnet.id}
instanceName: acc-test-mongodb-replica
chargeType: PostPaid
superAccountPassword: 93f0cb0614Aab12
projectName: default
tags:
- key: k1
value: v1
fooAccount:
type: volcengine:mongodb:Account
properties:
instanceId: ${fooInstance.id}
accountName: acc-test-mongodb-account
authDb: admin
accountPassword: 93f0cb0614Aab12
accountDesc: acc-test
accountPrivileges:
- dbName: admin
roleNames:
- userAdmin
- clusterMonitor
- dbName: config
roleNames:
- read
- dbName: local
roleNames:
- read
variables:
fooZones:
fn::invoke:
Function: volcengine:ecs:Zones
Arguments: {}
Create Account Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Account(name: string, args: AccountArgs, opts?: CustomResourceOptions);
@overload
def Account(resource_name: str,
args: AccountArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Account(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_name: Optional[str] = None,
account_password: Optional[str] = None,
instance_id: Optional[str] = None,
account_desc: Optional[str] = None,
account_privileges: Optional[Sequence[AccountAccountPrivilegeArgs]] = None,
auth_db: Optional[str] = None)
func NewAccount(ctx *Context, name string, args AccountArgs, opts ...ResourceOption) (*Account, error)
public Account(string name, AccountArgs args, CustomResourceOptions? opts = null)
public Account(String name, AccountArgs args)
public Account(String name, AccountArgs args, CustomResourceOptions options)
type: volcengine:mongodb:Account
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 AccountArgs
- 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 AccountArgs
- 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 AccountArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args AccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args AccountArgs
- 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 accountResource = new Volcengine.Mongodb.Account("accountResource", new()
{
AccountName = "string",
AccountPassword = "string",
InstanceId = "string",
AccountDesc = "string",
AccountPrivileges = new[]
{
new Volcengine.Mongodb.Inputs.AccountAccountPrivilegeArgs
{
DbName = "string",
RoleNames = new[]
{
"string",
},
},
},
AuthDb = "string",
});
example, err := mongodb.NewAccount(ctx, "accountResource", &mongodb.AccountArgs{
AccountName: pulumi.String("string"),
AccountPassword: pulumi.String("string"),
InstanceId: pulumi.String("string"),
AccountDesc: pulumi.String("string"),
AccountPrivileges: mongodb.AccountAccountPrivilegeArray{
&mongodb.AccountAccountPrivilegeArgs{
DbName: pulumi.String("string"),
RoleNames: pulumi.StringArray{
pulumi.String("string"),
},
},
},
AuthDb: pulumi.String("string"),
})
var accountResource = new com.pulumi.volcengine.mongodb.Account("accountResource", com.pulumi.volcengine.mongodb.AccountArgs.builder()
.accountName("string")
.accountPassword("string")
.instanceId("string")
.accountDesc("string")
.accountPrivileges(AccountAccountPrivilegeArgs.builder()
.dbName("string")
.roleNames("string")
.build())
.authDb("string")
.build());
account_resource = volcengine.mongodb.Account("accountResource",
account_name="string",
account_password="string",
instance_id="string",
account_desc="string",
account_privileges=[{
"db_name": "string",
"role_names": ["string"],
}],
auth_db="string")
const accountResource = new volcengine.mongodb.Account("accountResource", {
accountName: "string",
accountPassword: "string",
instanceId: "string",
accountDesc: "string",
accountPrivileges: [{
dbName: "string",
roleNames: ["string"],
}],
authDb: "string",
});
type: volcengine:mongodb:Account
properties:
accountDesc: string
accountName: string
accountPassword: string
accountPrivileges:
- dbName: string
roleNames:
- string
authDb: string
instanceId: string
Account 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 Account resource accepts the following input properties:
- Account
Name string - The name of the mongodb account.
- Account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Instance
Id string - The id of the mongodb instance.
- Account
Desc string - The description of the mongodb account.
- Account
Privileges List<AccountAccount Privilege> - The privilege information of account.
- Auth
Db string - The database of the mongodb account.
- Account
Name string - The name of the mongodb account.
- Account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Instance
Id string - The id of the mongodb instance.
- Account
Desc string - The description of the mongodb account.
- Account
Privileges []AccountAccount Privilege Args - The privilege information of account.
- Auth
Db string - The database of the mongodb account.
- account
Name String - The name of the mongodb account.
- account
Password String - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- instance
Id String - The id of the mongodb instance.
- account
Desc String - The description of the mongodb account.
- account
Privileges List<AccountAccount Privilege> - The privilege information of account.
- auth
Db String - The database of the mongodb account.
- account
Name string - The name of the mongodb account.
- account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- instance
Id string - The id of the mongodb instance.
- account
Desc string - The description of the mongodb account.
- account
Privileges AccountAccount Privilege[] - The privilege information of account.
- auth
Db string - The database of the mongodb account.
- account_
name str - The name of the mongodb account.
- account_
password str - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- instance_
id str - The id of the mongodb instance.
- account_
desc str - The description of the mongodb account.
- account_
privileges Sequence[AccountAccount Privilege Args] - The privilege information of account.
- auth_
db str - The database of the mongodb account.
- account
Name String - The name of the mongodb account.
- account
Password String - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- instance
Id String - The id of the mongodb instance.
- account
Desc String - The description of the mongodb account.
- account
Privileges List<Property Map> - The privilege information of account.
- auth
Db String - The database of the mongodb account.
Outputs
All input properties are implicitly available as output properties. Additionally, the Account resource produces the following output properties:
- Account
Type string - The type of the account.
- Id string
- The provider-assigned unique ID for this managed resource.
- Account
Type string - The type of the account.
- Id string
- The provider-assigned unique ID for this managed resource.
- account
Type String - The type of the account.
- id String
- The provider-assigned unique ID for this managed resource.
- account
Type string - The type of the account.
- id string
- The provider-assigned unique ID for this managed resource.
- account_
type str - The type of the account.
- id str
- The provider-assigned unique ID for this managed resource.
- account
Type String - The type of the account.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Account Resource
Get an existing Account 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?: AccountState, opts?: CustomResourceOptions): Account
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_desc: Optional[str] = None,
account_name: Optional[str] = None,
account_password: Optional[str] = None,
account_privileges: Optional[Sequence[AccountAccountPrivilegeArgs]] = None,
account_type: Optional[str] = None,
auth_db: Optional[str] = None,
instance_id: Optional[str] = None) -> Account
func GetAccount(ctx *Context, name string, id IDInput, state *AccountState, opts ...ResourceOption) (*Account, error)
public static Account Get(string name, Input<string> id, AccountState? state, CustomResourceOptions? opts = null)
public static Account get(String name, Output<String> id, AccountState state, CustomResourceOptions options)
resources: _: type: volcengine:mongodb:Account 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.
- Account
Desc string - The description of the mongodb account.
- Account
Name string - The name of the mongodb account.
- Account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Account
Privileges List<AccountAccount Privilege> - The privilege information of account.
- Account
Type string - The type of the account.
- Auth
Db string - The database of the mongodb account.
- Instance
Id string - The id of the mongodb instance.
- Account
Desc string - The description of the mongodb account.
- Account
Name string - The name of the mongodb account.
- Account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Account
Privileges []AccountAccount Privilege Args - The privilege information of account.
- Account
Type string - The type of the account.
- Auth
Db string - The database of the mongodb account.
- Instance
Id string - The id of the mongodb instance.
- account
Desc String - The description of the mongodb account.
- account
Name String - The name of the mongodb account.
- account
Password String - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- account
Privileges List<AccountAccount Privilege> - The privilege information of account.
- account
Type String - The type of the account.
- auth
Db String - The database of the mongodb account.
- instance
Id String - The id of the mongodb instance.
- account
Desc string - The description of the mongodb account.
- account
Name string - The name of the mongodb account.
- account
Password string - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- account
Privileges AccountAccount Privilege[] - The privilege information of account.
- account
Type string - The type of the account.
- auth
Db string - The database of the mongodb account.
- instance
Id string - The id of the mongodb instance.
- account_
desc str - The description of the mongodb account.
- account_
name str - The name of the mongodb account.
- account_
password str - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- account_
privileges Sequence[AccountAccount Privilege Args] - The privilege information of account.
- account_
type str - The type of the account.
- auth_
db str - The database of the mongodb account.
- instance_
id str - The id of the mongodb instance.
- account
Desc String - The description of the mongodb account.
- account
Name String - The name of the mongodb account.
- account
Password String - The password of the mongodb account. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- account
Privileges List<Property Map> - The privilege information of account.
- account
Type String - The type of the account.
- auth
Db String - The database of the mongodb account.
- instance
Id String - The id of the mongodb instance.
Supporting Types
AccountAccountPrivilege, AccountAccountPrivilegeArgs
- db_
name str - The name of database.
- role_
names Sequence[str] - The role names of the account.
Import
MongodbAccount can be imported using the instance_id:account_name, e.g.
$ pulumi import volcengine:mongodb/account:Account default resource_id
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
volcengine
Terraform Provider.