published on Thursday, Jul 9, 2026 by Volcengine
published on Thursday, Jul 9, 2026 by Volcengine
Database account.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcenginecc from "@volcengine/pulumi-volcenginecc";
const rDSMySQLDBAccountDemo = new volcenginecc.rdsmysql.DbAccount("RDSMySQLDBAccountDemo", {
accountDesc: "RDSMySQLDBAccountDemo desc",
instanceId: "mysql-a5b5caexxxxx",
accountName: "RDSMySQLDBAccountDemo",
accountPassword: "********",
accountType: "Normal",
accountPrivileges: [
{
account_privilege: "Custom",
account_privilege_detail: [
"CREATE",
"DROP",
"REFERENCES",
"INDEX",
],
db_name: "test",
},
{
account_privilege: "Global",
account_privilege_detail: [
"PROCESS",
"REPLICATION SLAVE",
"REPLICATION CLIENT",
"DROP",
"ALTER",
],
db_name: "",
},
],
host: "%",
tableColumnPrivileges: [],
});
import pulumi
import pulumi_volcenginecc as volcenginecc
r_ds_my_sqldb_account_demo = volcenginecc.rdsmysql.DbAccount("RDSMySQLDBAccountDemo",
account_desc="RDSMySQLDBAccountDemo desc",
instance_id="mysql-a5b5caexxxxx",
account_name="RDSMySQLDBAccountDemo",
account_password="********",
account_type="Normal",
account_privileges=[
{
"account_privilege": "Custom",
"account_privilege_detail": [
"CREATE",
"DROP",
"REFERENCES",
"INDEX",
],
"db_name": "test",
},
{
"account_privilege": "Global",
"account_privilege_detail": [
"PROCESS",
"REPLICATION SLAVE",
"REPLICATION CLIENT",
"DROP",
"ALTER",
],
"db_name": "",
},
],
host="%",
table_column_privileges=[])
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/volcengine/pulumi-volcenginecc/sdk/go/volcenginecc/rdsmysql"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := rdsmysql.NewDbAccount(ctx, "RDSMySQLDBAccountDemo", &rdsmysql.DbAccountArgs{
AccountDesc: pulumi.String("RDSMySQLDBAccountDemo desc"),
InstanceId: pulumi.String("mysql-a5b5caexxxxx"),
AccountName: pulumi.String("RDSMySQLDBAccountDemo"),
AccountPassword: pulumi.String("********"),
AccountType: pulumi.String("Normal"),
AccountPrivileges: rdsmysql.DbAccountAccountPrivilegeArray{
&rdsmysql.DbAccountAccountPrivilegeArgs{
Account_privilege: "Custom",
Account_privilege_detail: []string{
"CREATE",
"DROP",
"REFERENCES",
"INDEX",
},
Db_name: "test",
},
&rdsmysql.DbAccountAccountPrivilegeArgs{
Account_privilege: "Global",
Account_privilege_detail: []string{
"PROCESS",
"REPLICATION SLAVE",
"REPLICATION CLIENT",
"DROP",
"ALTER",
},
Db_name: "",
},
},
Host: pulumi.String("%"),
TableColumnPrivileges: rdsmysql.DbAccountTableColumnPrivilegeArray{},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcenginecc = Volcengine.Pulumi.Volcenginecc;
return await Deployment.RunAsync(() =>
{
var rDSMySQLDBAccountDemo = new Volcenginecc.Rdsmysql.DbAccount("RDSMySQLDBAccountDemo", new()
{
AccountDesc = "RDSMySQLDBAccountDemo desc",
InstanceId = "mysql-a5b5caexxxxx",
AccountName = "RDSMySQLDBAccountDemo",
AccountPassword = "********",
AccountType = "Normal",
AccountPrivileges = new[]
{
new Volcenginecc.Rdsmysql.Inputs.DbAccountAccountPrivilegeArgs
{
Account_privilege = "Custom",
Account_privilege_detail = new[]
{
"CREATE",
"DROP",
"REFERENCES",
"INDEX",
},
Db_name = "test",
},
new Volcenginecc.Rdsmysql.Inputs.DbAccountAccountPrivilegeArgs
{
Account_privilege = "Global",
Account_privilege_detail = new[]
{
"PROCESS",
"REPLICATION SLAVE",
"REPLICATION CLIENT",
"DROP",
"ALTER",
},
Db_name = "",
},
},
Host = "%",
TableColumnPrivileges = new[] {},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.volcengine.volcenginecc.rdsmysql.DbAccount;
import com.volcengine.volcenginecc.rdsmysql.DbAccountArgs;
import com.pulumi.volcenginecc.rdsmysql.inputs.DbAccountAccountPrivilegeArgs;
import java.util.ArrayList;
import java.util.Arrays;
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 rDSMySQLDBAccountDemo = new DbAccount("rDSMySQLDBAccountDemo", DbAccountArgs.builder()
.accountDesc("RDSMySQLDBAccountDemo desc")
.instanceId("mysql-a5b5caexxxxx")
.accountName("RDSMySQLDBAccountDemo")
.accountPassword("********")
.accountType("Normal")
.accountPrivileges(
DbAccountAccountPrivilegeArgs.builder()
.account_privilege("Custom")
.account_privilege_detail(Arrays.asList(
"CREATE",
"DROP",
"REFERENCES",
"INDEX"))
.db_name("test")
.build(),
DbAccountAccountPrivilegeArgs.builder()
.account_privilege("Global")
.account_privilege_detail(Arrays.asList(
"PROCESS",
"REPLICATION SLAVE",
"REPLICATION CLIENT",
"DROP",
"ALTER"))
.db_name("")
.build())
.host("%")
.tableColumnPrivileges()
.build());
}
}
resources:
rDSMySQLDBAccountDemo:
type: volcenginecc:rdsmysql:DbAccount
name: RDSMySQLDBAccountDemo
properties:
accountDesc: RDSMySQLDBAccountDemo desc
instanceId: mysql-a5b5caexxxxx
accountName: RDSMySQLDBAccountDemo
accountPassword: '********'
accountType: Normal
accountPrivileges:
- account_privilege: Custom
account_privilege_detail:
- CREATE
- DROP
- REFERENCES
- INDEX
db_name: test
- account_privilege: Global
account_privilege_detail:
- PROCESS
- REPLICATION SLAVE
- REPLICATION CLIENT
- DROP
- ALTER
db_name: ""
host: '%'
tableColumnPrivileges: []
pulumi {
required_providers {
volcenginecc = {
source = "pulumi/volcenginecc"
}
}
}
resource "volcenginecc_rdsmysql_dbaccount" "RDSMySQLDBAccountDemo" {
account_desc = "RDSMySQLDBAccountDemo desc"
instance_id = "mysql-a5b5caexxxxx"
account_name = "RDSMySQLDBAccountDemo"
account_password = "********"
account_type = "Normal"
account_privileges {
account_privilege = "Custom"
account_privilege_detail = ["CREATE", "DROP", "REFERENCES", "INDEX"]
db_name = "test"
}
account_privileges {
account_privilege = "Global"
account_privilege_detail = ["PROCESS", "REPLICATION SLAVE", "REPLICATION CLIENT", "DROP", "ALTER"]
db_name = ""
}
host = "%"
}
Create DbAccount Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new DbAccount(name: string, args: DbAccountArgs, opts?: CustomResourceOptions);@overload
def DbAccount(resource_name: str,
args: DbAccountArgs,
opts: Optional[ResourceOptions] = None)
@overload
def DbAccount(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_name: Optional[str] = None,
account_password: Optional[str] = None,
account_type: Optional[str] = None,
instance_id: Optional[str] = None,
account_desc: Optional[str] = None,
account_privileges: Optional[Sequence[DbAccountAccountPrivilegeArgs]] = None,
host: Optional[str] = None,
table_column_privileges: Optional[Sequence[DbAccountTableColumnPrivilegeArgs]] = None)func NewDbAccount(ctx *Context, name string, args DbAccountArgs, opts ...ResourceOption) (*DbAccount, error)public DbAccount(string name, DbAccountArgs args, CustomResourceOptions? opts = null)
public DbAccount(String name, DbAccountArgs args)
public DbAccount(String name, DbAccountArgs args, CustomResourceOptions options)
type: volcenginecc:rdsmysql:DbAccount
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "volcenginecc_rdsmysql_dbaccount" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args DbAccountArgs
- 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 DbAccountArgs
- 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 DbAccountArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DbAccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DbAccountArgs
- 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 dbAccountResource = new Volcenginecc.Rdsmysql.DbAccount("dbAccountResource", new()
{
AccountName = "string",
AccountPassword = "string",
AccountType = "string",
InstanceId = "string",
AccountDesc = "string",
AccountPrivileges = new[]
{
new Volcenginecc.Rdsmysql.Inputs.DbAccountAccountPrivilegeArgs
{
AccountPrivilege = "string",
AccountPrivilegeDetails = new[]
{
"string",
},
DbName = "string",
},
},
Host = "string",
TableColumnPrivileges = new[]
{
new Volcenginecc.Rdsmysql.Inputs.DbAccountTableColumnPrivilegeArgs
{
ColumnPrivileges = new[]
{
new Volcenginecc.Rdsmysql.Inputs.DbAccountTableColumnPrivilegeColumnPrivilegeArgs
{
AccountPrivilegeDetails = new[]
{
"string",
},
ColumnName = "string",
TableName = "string",
},
},
DbName = "string",
TablePrivileges = new[]
{
new Volcenginecc.Rdsmysql.Inputs.DbAccountTableColumnPrivilegeTablePrivilegeArgs
{
AccountPrivilegeDetails = new[]
{
"string",
},
TableName = "string",
},
},
},
},
});
example, err := rdsmysql.NewDbAccount(ctx, "dbAccountResource", &rdsmysql.DbAccountArgs{
AccountName: pulumi.String("string"),
AccountPassword: pulumi.String("string"),
AccountType: pulumi.String("string"),
InstanceId: pulumi.String("string"),
AccountDesc: pulumi.String("string"),
AccountPrivileges: rdsmysql.DbAccountAccountPrivilegeArray{
&rdsmysql.DbAccountAccountPrivilegeArgs{
AccountPrivilege: pulumi.String("string"),
AccountPrivilegeDetails: pulumi.StringArray{
pulumi.String("string"),
},
DbName: pulumi.String("string"),
},
},
Host: pulumi.String("string"),
TableColumnPrivileges: rdsmysql.DbAccountTableColumnPrivilegeArray{
&rdsmysql.DbAccountTableColumnPrivilegeArgs{
ColumnPrivileges: rdsmysql.DbAccountTableColumnPrivilegeColumnPrivilegeArray{
&rdsmysql.DbAccountTableColumnPrivilegeColumnPrivilegeArgs{
AccountPrivilegeDetails: pulumi.StringArray{
pulumi.String("string"),
},
ColumnName: pulumi.String("string"),
TableName: pulumi.String("string"),
},
},
DbName: pulumi.String("string"),
TablePrivileges: rdsmysql.DbAccountTableColumnPrivilegeTablePrivilegeArray{
&rdsmysql.DbAccountTableColumnPrivilegeTablePrivilegeArgs{
AccountPrivilegeDetails: pulumi.StringArray{
pulumi.String("string"),
},
TableName: pulumi.String("string"),
},
},
},
},
})
resource "volcenginecc_rdsmysql_dbaccount" "dbAccountResource" {
account_name = "string"
account_password = "string"
account_type = "string"
instance_id = "string"
account_desc = "string"
account_privileges {
account_privilege = "string"
account_privilege_details = ["string"]
db_name = "string"
}
host = "string"
table_column_privileges {
column_privileges {
account_privilege_details = ["string"]
column_name = "string"
table_name = "string"
}
db_name = "string"
table_privileges {
account_privilege_details = ["string"]
table_name = "string"
}
}
}
var dbAccountResource = new com.volcengine.volcenginecc.rdsmysql.DbAccount("dbAccountResource", com.volcengine.volcenginecc.rdsmysql.DbAccountArgs.builder()
.accountName("string")
.accountPassword("string")
.accountType("string")
.instanceId("string")
.accountDesc("string")
.accountPrivileges(DbAccountAccountPrivilegeArgs.builder()
.accountPrivilege("string")
.accountPrivilegeDetails("string")
.dbName("string")
.build())
.host("string")
.tableColumnPrivileges(DbAccountTableColumnPrivilegeArgs.builder()
.columnPrivileges(DbAccountTableColumnPrivilegeColumnPrivilegeArgs.builder()
.accountPrivilegeDetails("string")
.columnName("string")
.tableName("string")
.build())
.dbName("string")
.tablePrivileges(DbAccountTableColumnPrivilegeTablePrivilegeArgs.builder()
.accountPrivilegeDetails("string")
.tableName("string")
.build())
.build())
.build());
db_account_resource = volcenginecc.rdsmysql.DbAccount("dbAccountResource",
account_name="string",
account_password="string",
account_type="string",
instance_id="string",
account_desc="string",
account_privileges=[{
"account_privilege": "string",
"account_privilege_details": ["string"],
"db_name": "string",
}],
host="string",
table_column_privileges=[{
"column_privileges": [{
"account_privilege_details": ["string"],
"column_name": "string",
"table_name": "string",
}],
"db_name": "string",
"table_privileges": [{
"account_privilege_details": ["string"],
"table_name": "string",
}],
}])
const dbAccountResource = new volcenginecc.rdsmysql.DbAccount("dbAccountResource", {
accountName: "string",
accountPassword: "string",
accountType: "string",
instanceId: "string",
accountDesc: "string",
accountPrivileges: [{
accountPrivilege: "string",
accountPrivilegeDetails: ["string"],
dbName: "string",
}],
host: "string",
tableColumnPrivileges: [{
columnPrivileges: [{
accountPrivilegeDetails: ["string"],
columnName: "string",
tableName: "string",
}],
dbName: "string",
tablePrivileges: [{
accountPrivilegeDetails: ["string"],
tableName: "string",
}],
}],
});
type: volcenginecc:rdsmysql:DbAccount
properties:
accountDesc: string
accountName: string
accountPassword: string
accountPrivileges:
- accountPrivilege: string
accountPrivilegeDetails:
- string
dbName: string
accountType: string
host: string
instanceId: string
tableColumnPrivileges:
- columnPrivileges:
- accountPrivilegeDetails:
- string
columnName: string
tableName: string
dbName: string
tablePrivileges:
- accountPrivilegeDetails:
- string
tableName: string
DbAccount 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 DbAccount resource accepts the following input properties:
- Account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- Account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- Account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- Instance
Id string - Instance ID.
- Account
Desc string - Account information description, maximum length 256 characters.
- Account
Privileges List<Volcengine.Db Account Account Privilege> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Host string
- IP address from which the specified database account can access the database.
- Table
Column List<Volcengine.Privileges Db Account Table Column Privilege> - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- Account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- Account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- Instance
Id string - Instance ID.
- Account
Desc string - Account information description, maximum length 256 characters.
- Account
Privileges []DbAccount Account Privilege Args - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Host string
- IP address from which the specified database account can access the database.
- Table
Column []DbPrivileges Account Table Column Privilege Args - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account_
password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account_
type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- instance_
id string - Instance ID.
- account_
desc string - Account information description, maximum length 256 characters.
- account_
privileges list(object) - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- host string
- IP address from which the specified database account can access the database.
- table_
column_ list(object)privileges - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Name String - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password String - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Type String - Account type. Value options: Super: high-privilege account. Normal: regular account.
- instance
Id String - Instance ID.
- account
Desc String - Account information description, maximum length 256 characters.
- account
Privileges List<DbAccount Account Privilege> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- host String
- IP address from which the specified database account can access the database.
- table
Column List<DbPrivileges Account Table Column Privilege> - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- instance
Id string - Instance ID.
- account
Desc string - Account information description, maximum length 256 characters.
- account
Privileges DbAccount Account Privilege[] - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- host string
- IP address from which the specified database account can access the database.
- table
Column DbPrivileges Account Table Column Privilege[] - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
name str - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account_
password str - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account_
type str - Account type. Value options: Super: high-privilege account. Normal: regular account.
- instance_
id str - Instance ID.
- account_
desc str - Account information description, maximum length 256 characters.
- account_
privileges Sequence[DbAccount Account Privilege Args] - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- host str
- IP address from which the specified database account can access the database.
- table_
column_ Sequence[Dbprivileges Account Table Column Privilege Args] - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Name String - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password String - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Type String - Account type. Value options: Super: high-privilege account. Normal: regular account.
- instance
Id String - Instance ID.
- account
Desc String - Account information description, maximum length 256 characters.
- account
Privileges List<Property Map> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- host String
- IP address from which the specified database account can access the database.
- table
Column List<Property Map>Privileges - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
Outputs
All input properties are implicitly available as output properties. Additionally, the DbAccount resource produces the following output properties:
- Account
Privileges List<string>Sqls - SQL statement for the account's specified database permission information.
- Account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- Has
Table List<string>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- Id string
- The provider-assigned unique ID for this managed resource.
- Account
Privileges []stringSqls - SQL statement for the account's specified database permission information.
- Account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- Has
Table []stringColumn Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- Id string
- The provider-assigned unique ID for this managed resource.
- account_
privileges_ list(string)sqls - SQL statement for the account's specified database permission information.
- account_
status string - Account status. Values: Unavailable: unavailable. Available: available.
- has_
table_ list(string)column_ privilege_ db_ names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- id string
- The provider-assigned unique ID for this managed resource.
- account
Privileges List<String>Sqls - SQL statement for the account's specified database permission information.
- account
Status String - Account status. Values: Unavailable: unavailable. Available: available.
- has
Table List<String>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- id String
- The provider-assigned unique ID for this managed resource.
- account
Privileges string[]Sqls - SQL statement for the account's specified database permission information.
- account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- has
Table string[]Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- id string
- The provider-assigned unique ID for this managed resource.
- account_
privileges_ Sequence[str]sqls - SQL statement for the account's specified database permission information.
- account_
status str - Account status. Values: Unavailable: unavailable. Available: available.
- has_
table_ Sequence[str]column_ privilege_ db_ names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- id str
- The provider-assigned unique ID for this managed resource.
- account
Privileges List<String>Sqls - SQL statement for the account's specified database permission information.
- account
Status String - Account status. Values: Unavailable: unavailable. Available: available.
- has
Table List<String>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing DbAccount Resource
Get an existing DbAccount 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?: DbAccountState, opts?: CustomResourceOptions): DbAccount@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[DbAccountAccountPrivilegeArgs]] = None,
account_privileges_sqls: Optional[Sequence[str]] = None,
account_status: Optional[str] = None,
account_type: Optional[str] = None,
has_table_column_privilege_db_names: Optional[Sequence[str]] = None,
host: Optional[str] = None,
instance_id: Optional[str] = None,
table_column_privileges: Optional[Sequence[DbAccountTableColumnPrivilegeArgs]] = None) -> DbAccountfunc GetDbAccount(ctx *Context, name string, id IDInput, state *DbAccountState, opts ...ResourceOption) (*DbAccount, error)public static DbAccount Get(string name, Input<string> id, DbAccountState? state, CustomResourceOptions? opts = null)public static DbAccount get(String name, Output<String> id, DbAccountState state, CustomResourceOptions options)resources: _: type: volcenginecc:rdsmysql:DbAccount get: id: ${id}import {
to = volcenginecc_rdsmysql_dbaccount.example
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 - Account information description, maximum length 256 characters.
- Account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- Account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- Account
Privileges List<Volcengine.Db Account Account Privilege> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Account
Privileges List<string>Sqls - SQL statement for the account's specified database permission information.
- Account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- Account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- Has
Table List<string>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- Host string
- IP address from which the specified database account can access the database.
- Instance
Id string - Instance ID.
- Table
Column List<Volcengine.Privileges Db Account Table Column Privilege> - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Account
Desc string - Account information description, maximum length 256 characters.
- Account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- Account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- Account
Privileges []DbAccount Account Privilege Args - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Account
Privileges []stringSqls - SQL statement for the account's specified database permission information.
- Account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- Account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- Has
Table []stringColumn Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- Host string
- IP address from which the specified database account can access the database.
- Instance
Id string - Instance ID.
- Table
Column []DbPrivileges Account Table Column Privilege Args - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
desc string - Account information description, maximum length 256 characters.
- account_
name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account_
password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account_
privileges list(object) - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
privileges_ list(string)sqls - SQL statement for the account's specified database permission information.
- account_
status string - Account status. Values: Unavailable: unavailable. Available: available.
- account_
type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- has_
table_ list(string)column_ privilege_ db_ names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- host string
- IP address from which the specified database account can access the database.
- instance_
id string - Instance ID.
- table_
column_ list(object)privileges - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Desc String - Account information description, maximum length 256 characters.
- account
Name String - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password String - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Privileges List<DbAccount Account Privilege> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Privileges List<String>Sqls - SQL statement for the account's specified database permission information.
- account
Status String - Account status. Values: Unavailable: unavailable. Available: available.
- account
Type String - Account type. Value options: Super: high-privilege account. Normal: regular account.
- has
Table List<String>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- host String
- IP address from which the specified database account can access the database.
- instance
Id String - Instance ID.
- table
Column List<DbPrivileges Account Table Column Privilege> - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Desc string - Account information description, maximum length 256 characters.
- account
Name string - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password string - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Privileges DbAccount Account Privilege[] - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Privileges string[]Sqls - SQL statement for the account's specified database permission information.
- account
Status string - Account status. Values: Unavailable: unavailable. Available: available.
- account
Type string - Account type. Value options: Super: high-privilege account. Normal: regular account.
- has
Table string[]Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- host string
- IP address from which the specified database account can access the database.
- instance
Id string - Instance ID.
- table
Column DbPrivileges Account Table Column Privilege[] - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
desc str - Account information description, maximum length 256 characters.
- account_
name str - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account_
password str - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account_
privileges Sequence[DbAccount Account Privilege Args] - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account_
privileges_ Sequence[str]sqls - SQL statement for the account's specified database permission information.
- account_
status str - Account status. Values: Unavailable: unavailable. Available: available.
- account_
type str - Account type. Value options: Super: high-privilege account. Normal: regular account.
- has_
table_ Sequence[str]column_ privilege_ db_ names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- host str
- IP address from which the specified database account can access the database.
- instance_
id str - Instance ID.
- table_
column_ Sequence[Dbprivileges Account Table Column Privilege Args] - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Desc String - Account information description, maximum length 256 characters.
- account
Name String - Database account name. Naming rules: Must be 2–32 characters long. Must start with a letter and end with a letter or number. Can contain letters, numbers, underscores (_), and hyphens (-). The account name must be unique within the instance. Certain reserved words cannot be used; for disabled reserved words, see the disabled word list. Note: The keywords root and admin can be used in high-privilege account names.
- account
Password String - Database account password. Rules: Length must be 8–32 characters. Must include at least three of the following: uppercase letters, lowercase letters, numbers, special characters. Allowed special characters: !@#$%^&*()_+-=,.&?|/.
- account
Privileges List<Property Map> - Specified database privilege information for the account. Note: When AccountType is set to Super, AccountPrivileges does not need to be specified. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- account
Privileges List<String>Sqls - SQL statement for the account's specified database permission information.
- account
Status String - Account status. Values: Unavailable: unavailable. Available: available.
- account
Type String - Account type. Value options: Super: high-privilege account. Normal: regular account.
- has
Table List<String>Column Privilege Db Names - The database to which the account's table/column privileges belong. Note: If the account does not have table/column privileges, this field will not be returned.
- host String
- IP address from which the specified database account can access the database.
- instance
Id String - Instance ID.
- table
Column List<Property Map>Privileges - Account table column permission settings. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
Supporting Types
DbAccountAccountPrivilege, DbAccountAccountPrivilegeArgs
- Account
Privilege string - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- Account
Privilege List<string>Details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- Db
Name string - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- Account
Privilege string - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- Account
Privilege []stringDetails - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- Db
Name string - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- account_
privilege string - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- account_
privilege_ list(string)details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- db_
name string - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- account
Privilege String - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- account
Privilege List<String>Details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- db
Name String - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- account
Privilege string - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- account
Privilege string[]Details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- db
Name string - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- account_
privilege str - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- account_
privilege_ Sequence[str]details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- db_
name str - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
- account
Privilege String - Type of database permission. Value options: ReadWrite: read and write permission. ReadOnly: read-only permission. DDLOnly: DDL permission only. DMLOnly: DML permission only. Custom: custom permission. Global: global permission. None: clear account permission. Note: When used as a request parameter, pay attention to the following: Only Global and None are allowed as values when used as request parameters. Permission type is single-select; passing multiple values will result in an error. Only the GrantDBAccountPrivilege API supports None as a value for AccountPrivilege. When AccountPrivilege is set to None and DBName is an empty string, all global permissions for the account are cleared. If DBName is set to a specific database, all permissions for the account in that database are cleared.
- account
Privilege List<String>Details - Account privilege information. When AccountPrivilege is set to Custom, the valid values for this field are: SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, REFERENCES, INDEX, ALTER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, EVENT, TRIGGER, CREATE ROUTINE, ALTER ROUTINE. When AccountPrivilege is set to Global, the valid values for this field are: PROCESS, REPLICATION SLAVE, REPLICATION CLIENT, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, REFERENCES, INDEX, ALTER, LOCK TABLES, EXECUTE, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, SHOW DATABASES, CREATE TEMPORARY TABLES. Note: When used as a request parameter, this field is required if AccountPrivilege is set to Custom. In the CreateDBAccount API, REPLICATION SLAVE, PROCESS, and REPLICATION CLIENT global privileges are automatically granted to the account. Multiple values can be specified, separated by commas (,). The write mode is overwrite.
- db
Name String - The name of the database for which account authorization needs to be modified or for which the account already has privileges. Note: When used as a request parameter in the CreateDBAccount and GrantDBAccountPrivilege APIs, ensure that the database corresponding to DBName already exists. For global privilege modifications, set DBName to an empty string.
DbAccountTableColumnPrivilege, DbAccountTableColumnPrivilegeArgs
- Column
Privileges List<Volcengine.Db Account Table Column Privilege Column Privilege> - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Db
Name string - Name of the database to which the table belongs for setting permissions for the account.
- Table
Privileges List<Volcengine.Db Account Table Column Privilege Table Privilege> - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Column
Privileges []DbAccount Table Column Privilege Column Privilege - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- Db
Name string - Name of the database to which the table belongs for setting permissions for the account.
- Table
Privileges []DbAccount Table Column Privilege Table Privilege - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- column_
privileges list(object) - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- db_
name string - Name of the database to which the table belongs for setting permissions for the account.
- table_
privileges list(object) - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- column
Privileges List<DbAccount Table Column Privilege Column Privilege> - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- db
Name String - Name of the database to which the table belongs for setting permissions for the account.
- table
Privileges List<DbAccount Table Column Privilege Table Privilege> - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- column
Privileges DbAccount Table Column Privilege Column Privilege[] - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- db
Name string - Name of the database to which the table belongs for setting permissions for the account.
- table
Privileges DbAccount Table Column Privilege Table Privilege[] - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- column_
privileges Sequence[DbAccount Table Column Privilege Column Privilege] - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- db_
name str - Name of the database to which the table belongs for setting permissions for the account.
- table_
privileges Sequence[DbAccount Table Column Privilege Table Privilege] - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- column
Privileges List<Property Map> - Account column permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
- db
Name String - Name of the database to which the table belongs for setting permissions for the account.
- table
Privileges List<Property Map> - Account table permission information. Important Note: When using SetNestedAttribute, you must fully define all attributes of its nested structure. Incomplete definitions may cause Terraform to detect unexpected differences during plan comparison, triggering unnecessary resource updates and affecting resource stability and predictability.
DbAccountTableColumnPrivilegeColumnPrivilege, DbAccountTableColumnPrivilegeColumnPrivilegeArgs
- Account
Privilege List<string>Details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- Column
Name string - Name of the column for setting column permissions for the account.
- Table
Name string - Name of the database to which the table belongs for setting column permissions for the account.
- Account
Privilege []stringDetails - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- Column
Name string - Name of the column for setting column permissions for the account.
- Table
Name string - Name of the database to which the table belongs for setting column permissions for the account.
- account_
privilege_ list(string)details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- column_
name string - Name of the column for setting column permissions for the account.
- table_
name string - Name of the database to which the table belongs for setting column permissions for the account.
- account
Privilege List<String>Details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- column
Name String - Name of the column for setting column permissions for the account.
- table
Name String - Name of the database to which the table belongs for setting column permissions for the account.
- account
Privilege string[]Details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- column
Name string - Name of the column for setting column permissions for the account.
- table
Name string - Name of the database to which the table belongs for setting column permissions for the account.
- account_
privilege_ Sequence[str]details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- column_
name str - Name of the column for setting column permissions for the account.
- table_
name str - Name of the database to which the table belongs for setting column permissions for the account.
- account
Privilege List<String>Details - Permission information for setting column permissions for the account. Values (multiple selections allowed): INSERT, REFERENCES, SELECT, UPDATE. Note: Use commas (,) to separate multiple permissions.
- column
Name String - Name of the column for setting column permissions for the account.
- table
Name String - Name of the database to which the table belongs for setting column permissions for the account.
DbAccountTableColumnPrivilegeTablePrivilege, DbAccountTableColumnPrivilegeTablePrivilegeArgs
- Account
Privilege List<string>Details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- Table
Name string - Name of the table for setting permissions for the account.
- Account
Privilege []stringDetails - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- Table
Name string - Name of the table for setting permissions for the account.
- account_
privilege_ list(string)details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- table_
name string - Name of the table for setting permissions for the account.
- account
Privilege List<String>Details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- table
Name String - Name of the table for setting permissions for the account.
- account
Privilege string[]Details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- table
Name string - Name of the table for setting permissions for the account.
- account_
privilege_ Sequence[str]details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- table_
name str - Name of the table for setting permissions for the account.
- account
Privilege List<String>Details - Account table permissions. Value options (multiple selections allowed): ALTER, CREATE, DELETE, DROP, INDEX, INSERT, SELECT, SHOW, VIEW, TRIGGER, UPDATE, CREATE VIEW, REFERENCES. Note: Use commas (,) to separate multiple permissions.
- table
Name String - Name of the table for setting permissions for the account.
Import
$ pulumi import volcenginecc:rdsmysql/dbAccount:DbAccount example "instance_id|account_name|host"
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- volcenginecc volcengine/pulumi-volcenginecc
- License
- MPL-2.0
- Notes
- This Pulumi package is based on the
volcengineccTerraform Provider.
published on Thursday, Jul 9, 2026 by Volcengine