1. Packages
  2. Flexibleengine Provider
  3. API Docs
  4. DdsDatabaseUser
flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud

flexibleengine.DdsDatabaseUser

Explore with Pulumi AI

flexibleengine logo
flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud

    Manages a database user resource within FlexibleEngine.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as flexibleengine from "@pulumi/flexibleengine";
    
    const config = new pulumi.Config();
    const instanceId = config.requireObject("instanceId");
    const userName = config.requireObject("userName");
    const userPassword = config.requireObject("userPassword");
    const ownedRoleName = config.requireObject("ownedRoleName");
    const ownedRoleDbName = config.requireObject("ownedRoleDbName");
    const test = new flexibleengine.DdsDatabaseUser("test", {
        instanceId: instanceId,
        password: userPassword,
        dbName: _var.db_name,
        roles: [{
            name: ownedRoleName,
            dbName: ownedRoleDbName,
        }],
    });
    
    import pulumi
    import pulumi_flexibleengine as flexibleengine
    
    config = pulumi.Config()
    instance_id = config.require_object("instanceId")
    user_name = config.require_object("userName")
    user_password = config.require_object("userPassword")
    owned_role_name = config.require_object("ownedRoleName")
    owned_role_db_name = config.require_object("ownedRoleDbName")
    test = flexibleengine.DdsDatabaseUser("test",
        instance_id=instance_id,
        password=user_password,
        db_name=var["db_name"],
        roles=[{
            "name": owned_role_name,
            "db_name": owned_role_db_name,
        }])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/flexibleengine/flexibleengine"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		instanceId := cfg.RequireObject("instanceId")
    		userName := cfg.RequireObject("userName")
    		userPassword := cfg.RequireObject("userPassword")
    		ownedRoleName := cfg.RequireObject("ownedRoleName")
    		ownedRoleDbName := cfg.RequireObject("ownedRoleDbName")
    		_, err := flexibleengine.NewDdsDatabaseUser(ctx, "test", &flexibleengine.DdsDatabaseUserArgs{
    			InstanceId: pulumi.Any(instanceId),
    			Password:   pulumi.Any(userPassword),
    			DbName:     pulumi.Any(_var.Db_name),
    			Roles: flexibleengine.DdsDatabaseUserRoleArray{
    				&flexibleengine.DdsDatabaseUserRoleArgs{
    					Name:   pulumi.Any(ownedRoleName),
    					DbName: pulumi.Any(ownedRoleDbName),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Flexibleengine = Pulumi.Flexibleengine;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var instanceId = config.RequireObject<dynamic>("instanceId");
        var userName = config.RequireObject<dynamic>("userName");
        var userPassword = config.RequireObject<dynamic>("userPassword");
        var ownedRoleName = config.RequireObject<dynamic>("ownedRoleName");
        var ownedRoleDbName = config.RequireObject<dynamic>("ownedRoleDbName");
        var test = new Flexibleengine.DdsDatabaseUser("test", new()
        {
            InstanceId = instanceId,
            Password = userPassword,
            DbName = @var.Db_name,
            Roles = new[]
            {
                new Flexibleengine.Inputs.DdsDatabaseUserRoleArgs
                {
                    Name = ownedRoleName,
                    DbName = ownedRoleDbName,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.flexibleengine.DdsDatabaseUser;
    import com.pulumi.flexibleengine.DdsDatabaseUserArgs;
    import com.pulumi.flexibleengine.inputs.DdsDatabaseUserRoleArgs;
    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 config = ctx.config();
            final var instanceId = config.get("instanceId");
            final var userName = config.get("userName");
            final var userPassword = config.get("userPassword");
            final var ownedRoleName = config.get("ownedRoleName");
            final var ownedRoleDbName = config.get("ownedRoleDbName");
            var test = new DdsDatabaseUser("test", DdsDatabaseUserArgs.builder()
                .instanceId(instanceId)
                .password(userPassword)
                .dbName(var_.db_name())
                .roles(DdsDatabaseUserRoleArgs.builder()
                    .name(ownedRoleName)
                    .dbName(ownedRoleDbName)
                    .build())
                .build());
    
        }
    }
    
    configuration:
      instanceId:
        type: dynamic
      userName:
        type: dynamic
      userPassword:
        type: dynamic
      ownedRoleName:
        type: dynamic
      ownedRoleDbName:
        type: dynamic
    resources:
      test:
        type: flexibleengine:DdsDatabaseUser
        properties:
          instanceId: ${instanceId}
          password: ${userPassword}
          dbName: ${var.db_name}
          roles:
            - name: ${ownedRoleName}
              dbName: ${ownedRoleDbName}
    

    Create DdsDatabaseUser Resource

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

    Constructor syntax

    new DdsDatabaseUser(name: string, args: DdsDatabaseUserArgs, opts?: CustomResourceOptions);
    @overload
    def DdsDatabaseUser(resource_name: str,
                        args: DdsDatabaseUserArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def DdsDatabaseUser(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        db_name: Optional[str] = None,
                        instance_id: Optional[str] = None,
                        password: Optional[str] = None,
                        roles: Optional[Sequence[DdsDatabaseUserRoleArgs]] = None,
                        dds_database_user_id: Optional[str] = None,
                        name: Optional[str] = None,
                        region: Optional[str] = None,
                        timeouts: Optional[DdsDatabaseUserTimeoutsArgs] = None)
    func NewDdsDatabaseUser(ctx *Context, name string, args DdsDatabaseUserArgs, opts ...ResourceOption) (*DdsDatabaseUser, error)
    public DdsDatabaseUser(string name, DdsDatabaseUserArgs args, CustomResourceOptions? opts = null)
    public DdsDatabaseUser(String name, DdsDatabaseUserArgs args)
    public DdsDatabaseUser(String name, DdsDatabaseUserArgs args, CustomResourceOptions options)
    
    type: flexibleengine:DdsDatabaseUser
    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 DdsDatabaseUserArgs
    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 DdsDatabaseUserArgs
    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 DdsDatabaseUserArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DdsDatabaseUserArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DdsDatabaseUserArgs
    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 ddsDatabaseUserResource = new Flexibleengine.DdsDatabaseUser("ddsDatabaseUserResource", new()
    {
        DbName = "string",
        InstanceId = "string",
        Password = "string",
        Roles = new[]
        {
            new Flexibleengine.Inputs.DdsDatabaseUserRoleArgs
            {
                DbName = "string",
                Name = "string",
            },
        },
        DdsDatabaseUserId = "string",
        Name = "string",
        Region = "string",
        Timeouts = new Flexibleengine.Inputs.DdsDatabaseUserTimeoutsArgs
        {
            Create = "string",
            Delete = "string",
            Update = "string",
        },
    });
    
    example, err := flexibleengine.NewDdsDatabaseUser(ctx, "ddsDatabaseUserResource", &flexibleengine.DdsDatabaseUserArgs{
    	DbName:     pulumi.String("string"),
    	InstanceId: pulumi.String("string"),
    	Password:   pulumi.String("string"),
    	Roles: flexibleengine.DdsDatabaseUserRoleArray{
    		&flexibleengine.DdsDatabaseUserRoleArgs{
    			DbName: pulumi.String("string"),
    			Name:   pulumi.String("string"),
    		},
    	},
    	DdsDatabaseUserId: pulumi.String("string"),
    	Name:              pulumi.String("string"),
    	Region:            pulumi.String("string"),
    	Timeouts: &flexibleengine.DdsDatabaseUserTimeoutsArgs{
    		Create: pulumi.String("string"),
    		Delete: pulumi.String("string"),
    		Update: pulumi.String("string"),
    	},
    })
    
    var ddsDatabaseUserResource = new DdsDatabaseUser("ddsDatabaseUserResource", DdsDatabaseUserArgs.builder()
        .dbName("string")
        .instanceId("string")
        .password("string")
        .roles(DdsDatabaseUserRoleArgs.builder()
            .dbName("string")
            .name("string")
            .build())
        .ddsDatabaseUserId("string")
        .name("string")
        .region("string")
        .timeouts(DdsDatabaseUserTimeoutsArgs.builder()
            .create("string")
            .delete("string")
            .update("string")
            .build())
        .build());
    
    dds_database_user_resource = flexibleengine.DdsDatabaseUser("ddsDatabaseUserResource",
        db_name="string",
        instance_id="string",
        password="string",
        roles=[{
            "db_name": "string",
            "name": "string",
        }],
        dds_database_user_id="string",
        name="string",
        region="string",
        timeouts={
            "create": "string",
            "delete": "string",
            "update": "string",
        })
    
    const ddsDatabaseUserResource = new flexibleengine.DdsDatabaseUser("ddsDatabaseUserResource", {
        dbName: "string",
        instanceId: "string",
        password: "string",
        roles: [{
            dbName: "string",
            name: "string",
        }],
        ddsDatabaseUserId: "string",
        name: "string",
        region: "string",
        timeouts: {
            create: "string",
            "delete": "string",
            update: "string",
        },
    });
    
    type: flexibleengine:DdsDatabaseUser
    properties:
        dbName: string
        ddsDatabaseUserId: string
        instanceId: string
        name: string
        password: string
        region: string
        roles:
            - dbName: string
              name: string
        timeouts:
            create: string
            delete: string
            update: string
    

    DdsDatabaseUser 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 DdsDatabaseUser resource accepts the following input properties:

    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    InstanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    Password string
    Specifies the user password. The assword content must meet the following conditions:
    Roles List<DdsDatabaseUserRole>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    DdsDatabaseUserId string
    The resource ID.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    Region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    Timeouts DdsDatabaseUserTimeouts
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    InstanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    Password string
    Specifies the user password. The assword content must meet the following conditions:
    Roles []DdsDatabaseUserRoleArgs

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    DdsDatabaseUserId string
    The resource ID.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    Region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    Timeouts DdsDatabaseUserTimeoutsArgs
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    instanceId String
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    password String
    Specifies the user password. The assword content must meet the following conditions:
    roles List<DdsDatabaseUserRole>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    ddsDatabaseUserId String
    The resource ID.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    region String
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    timeouts DdsDatabaseUserTimeouts
    dbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    instanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    password string
    Specifies the user password. The assword content must meet the following conditions:
    roles DdsDatabaseUserRole[]

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    ddsDatabaseUserId string
    The resource ID.
    name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    timeouts DdsDatabaseUserTimeouts
    db_name str
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    instance_id str
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    password str
    Specifies the user password. The assword content must meet the following conditions:
    roles Sequence[DdsDatabaseUserRoleArgs]

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    dds_database_user_id str
    The resource ID.
    name str
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    region str
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    timeouts DdsDatabaseUserTimeoutsArgs
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    instanceId String
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    password String
    Specifies the user password. The assword content must meet the following conditions:
    roles List<Property Map>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    ddsDatabaseUserId String
    The resource ID.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    region String
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    timeouts Property Map

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    InheritedPrivileges List<DdsDatabaseUserInheritedPrivilege>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    Privileges List<DdsDatabaseUserPrivilege>
    The list of database privileges owned by the current user. The object structure is documented below.
    Id string
    The provider-assigned unique ID for this managed resource.
    InheritedPrivileges []DdsDatabaseUserInheritedPrivilege
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    Privileges []DdsDatabaseUserPrivilege
    The list of database privileges owned by the current user. The object structure is documented below.
    id String
    The provider-assigned unique ID for this managed resource.
    inheritedPrivileges List<DdsDatabaseUserInheritedPrivilege>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    privileges List<DdsDatabaseUserPrivilege>
    The list of database privileges owned by the current user. The object structure is documented below.
    id string
    The provider-assigned unique ID for this managed resource.
    inheritedPrivileges DdsDatabaseUserInheritedPrivilege[]
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    privileges DdsDatabaseUserPrivilege[]
    The list of database privileges owned by the current user. The object structure is documented below.
    id str
    The provider-assigned unique ID for this managed resource.
    inherited_privileges Sequence[DdsDatabaseUserInheritedPrivilege]
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    privileges Sequence[DdsDatabaseUserPrivilege]
    The list of database privileges owned by the current user. The object structure is documented below.
    id String
    The provider-assigned unique ID for this managed resource.
    inheritedPrivileges List<Property Map>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    privileges List<Property Map>
    The list of database privileges owned by the current user. The object structure is documented below.

    Look up Existing DdsDatabaseUser Resource

    Get an existing DdsDatabaseUser 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?: DdsDatabaseUserState, opts?: CustomResourceOptions): DdsDatabaseUser
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            db_name: Optional[str] = None,
            dds_database_user_id: Optional[str] = None,
            inherited_privileges: Optional[Sequence[DdsDatabaseUserInheritedPrivilegeArgs]] = None,
            instance_id: Optional[str] = None,
            name: Optional[str] = None,
            password: Optional[str] = None,
            privileges: Optional[Sequence[DdsDatabaseUserPrivilegeArgs]] = None,
            region: Optional[str] = None,
            roles: Optional[Sequence[DdsDatabaseUserRoleArgs]] = None,
            timeouts: Optional[DdsDatabaseUserTimeoutsArgs] = None) -> DdsDatabaseUser
    func GetDdsDatabaseUser(ctx *Context, name string, id IDInput, state *DdsDatabaseUserState, opts ...ResourceOption) (*DdsDatabaseUser, error)
    public static DdsDatabaseUser Get(string name, Input<string> id, DdsDatabaseUserState? state, CustomResourceOptions? opts = null)
    public static DdsDatabaseUser get(String name, Output<String> id, DdsDatabaseUserState state, CustomResourceOptions options)
    resources:  _:    type: flexibleengine:DdsDatabaseUser    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.
    The following state arguments are supported:
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    DdsDatabaseUserId string
    The resource ID.
    InheritedPrivileges List<DdsDatabaseUserInheritedPrivilege>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    InstanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    Password string
    Specifies the user password. The assword content must meet the following conditions:
    Privileges List<DdsDatabaseUserPrivilege>
    The list of database privileges owned by the current user. The object structure is documented below.
    Region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    Roles List<DdsDatabaseUserRole>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    Timeouts DdsDatabaseUserTimeouts
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    DdsDatabaseUserId string
    The resource ID.
    InheritedPrivileges []DdsDatabaseUserInheritedPrivilegeArgs
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    InstanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    Password string
    Specifies the user password. The assword content must meet the following conditions:
    Privileges []DdsDatabaseUserPrivilegeArgs
    The list of database privileges owned by the current user. The object structure is documented below.
    Region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    Roles []DdsDatabaseUserRoleArgs

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    Timeouts DdsDatabaseUserTimeoutsArgs
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    ddsDatabaseUserId String
    The resource ID.
    inheritedPrivileges List<DdsDatabaseUserInheritedPrivilege>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    instanceId String
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    password String
    Specifies the user password. The assword content must meet the following conditions:
    privileges List<DdsDatabaseUserPrivilege>
    The list of database privileges owned by the current user. The object structure is documented below.
    region String
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    roles List<DdsDatabaseUserRole>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    timeouts DdsDatabaseUserTimeouts
    dbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    ddsDatabaseUserId string
    The resource ID.
    inheritedPrivileges DdsDatabaseUserInheritedPrivilege[]
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    instanceId string
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    password string
    Specifies the user password. The assword content must meet the following conditions:
    privileges DdsDatabaseUserPrivilege[]
    The list of database privileges owned by the current user. The object structure is documented below.
    region string
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    roles DdsDatabaseUserRole[]

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    timeouts DdsDatabaseUserTimeouts
    db_name str
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    dds_database_user_id str
    The resource ID.
    inherited_privileges Sequence[DdsDatabaseUserInheritedPrivilegeArgs]
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    instance_id str
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    name str
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    password str
    Specifies the user password. The assword content must meet the following conditions:
    privileges Sequence[DdsDatabaseUserPrivilegeArgs]
    The list of database privileges owned by the current user. The object structure is documented below.
    region str
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    roles Sequence[DdsDatabaseUserRoleArgs]

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    timeouts DdsDatabaseUserTimeoutsArgs
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    ddsDatabaseUserId String
    The resource ID.
    inheritedPrivileges List<Property Map>
    The list of database privileges owned by the current user, includes all privileges inherited by owned roles. The object structure is documented below.
    instanceId String
    Specifies the DDS instance ID to which the user belongs. Changing this parameter will create a new user.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    password String
    Specifies the user password. The assword content must meet the following conditions:
    privileges List<Property Map>
    The list of database privileges owned by the current user. The object structure is documented below.
    region String
    Specifies the region where the DDS instance is located. Changing this parameter will create a new user.
    roles List<Property Map>

    Specifies the list of roles owned by the current user. The object structure is documented below. Changing this parameter will create a new user.

    The roles block supports:

    timeouts Property Map

    Supporting Types

    DdsDatabaseUserInheritedPrivilege, DdsDatabaseUserInheritedPrivilegeArgs

    Actions List<string>
    The operation permission list.
    Resources List<DdsDatabaseUserInheritedPrivilegeResource>
    The details of the resource to which the privilege belongs. The object structure is documented below.
    Actions []string
    The operation permission list.
    Resources []DdsDatabaseUserInheritedPrivilegeResource
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions List<String>
    The operation permission list.
    resources List<DdsDatabaseUserInheritedPrivilegeResource>
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions string[]
    The operation permission list.
    resources DdsDatabaseUserInheritedPrivilegeResource[]
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions Sequence[str]
    The operation permission list.
    resources Sequence[DdsDatabaseUserInheritedPrivilegeResource]
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions List<String>
    The operation permission list.
    resources List<Property Map>
    The details of the resource to which the privilege belongs. The object structure is documented below.

    DdsDatabaseUserInheritedPrivilegeResource, DdsDatabaseUserInheritedPrivilegeResourceArgs

    Collection string
    The database collection type.
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    Collection string
    The database collection type.
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection String
    The database collection type.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection string
    The database collection type.
    dbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection str
    The database collection type.
    db_name str
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection String
    The database collection type.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.

    DdsDatabaseUserPrivilege, DdsDatabaseUserPrivilegeArgs

    Actions List<string>
    The operation permission list.
    Resources List<DdsDatabaseUserPrivilegeResource>
    The details of the resource to which the privilege belongs. The object structure is documented below.
    Actions []string
    The operation permission list.
    Resources []DdsDatabaseUserPrivilegeResource
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions List<String>
    The operation permission list.
    resources List<DdsDatabaseUserPrivilegeResource>
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions string[]
    The operation permission list.
    resources DdsDatabaseUserPrivilegeResource[]
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions Sequence[str]
    The operation permission list.
    resources Sequence[DdsDatabaseUserPrivilegeResource]
    The details of the resource to which the privilege belongs. The object structure is documented below.
    actions List<String>
    The operation permission list.
    resources List<Property Map>
    The details of the resource to which the privilege belongs. The object structure is documented below.

    DdsDatabaseUserPrivilegeResource, DdsDatabaseUserPrivilegeResourceArgs

    Collection string
    The database collection type.
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    Collection string
    The database collection type.
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection String
    The database collection type.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection string
    The database collection type.
    dbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection str
    The database collection type.
    db_name str
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    collection String
    The database collection type.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.

    DdsDatabaseUserRole, DdsDatabaseUserRoleArgs

    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    DbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    Name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    dbName string
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    name string
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    db_name str
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    name str
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.
    dbName String
    Specifies the database name to which this owned role belongs. Changing this parameter will create a new user.
    name String
    Specifies the name of role owned by the current user. The name can contain 1 to 64 characters, only letters, digits, underscores (_), hyphens (-) and dots (.) are allowed. Changing this parameter will create a new user.

    DdsDatabaseUserTimeouts, DdsDatabaseUserTimeoutsArgs

    Create string
    Delete string
    Update string
    Create string
    Delete string
    Update string
    create String
    delete String
    update String
    create string
    delete string
    update string
    create str
    delete str
    update str
    create String
    delete String
    update String

    Import

    Database users can be imported using their id (combination of instance_id, db_name and name), separated by a

    slash (/), e.g.

    $ pulumi import flexibleengine:index/ddsDatabaseUser:DdsDatabaseUser test <instance_id>/<db_name>/<name>
    

    Due to security reason, the imported state may not be identical to your resource definition (password parameter).

    It is generally recommended running pulumi preview after importing a user resource.

    You can then decide if changes should be applied to the user, or the resource definition should be updated to align with

    the user. Also you can ignore changes as below.

    hcl

    resource “flexibleengine_dds_database_user” “test” {

    lifecycle {

    ignore_changes = [
    
      password,
    
    ]
    

    }

    }

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

    Package Details

    Repository
    flexibleengine flexibleenginecloud/terraform-provider-flexibleengine
    License
    Notes
    This Pulumi package is based on the flexibleengine Terraform Provider.
    flexibleengine logo
    flexibleengine 1.46.0 published on Monday, Apr 14, 2025 by flexibleenginecloud