1. Packages
  2. Databricks Provider
  3. API Docs
  4. DatabaseInstance
Databricks v1.71.0 published on Monday, Jun 9, 2025 by Pulumi

databricks.DatabaseInstance

Explore with Pulumi AI

databricks logo
Databricks v1.71.0 published on Monday, Jun 9, 2025 by Pulumi

    Import

    As of terraform v1.5, resources can be imported through configuration.

    hcl

    import {

    id = name

    to = databricks_database_instance.this

    }

    If you are using an older version of terraform, you can import the resource using cli as follows:

    $ pulumi import databricks:index/databaseInstance:DatabaseInstance databricks_database_instance name
    

    Create DatabaseInstance Resource

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

    Constructor syntax

    new DatabaseInstance(name: string, args?: DatabaseInstanceArgs, opts?: CustomResourceOptions);
    @overload
    def DatabaseInstance(resource_name: str,
                         args: Optional[DatabaseInstanceArgs] = None,
                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def DatabaseInstance(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         admin_password: Optional[str] = None,
                         admin_rolename: Optional[str] = None,
                         capacity: Optional[str] = None,
                         name: Optional[str] = None,
                         stopped: Optional[bool] = None)
    func NewDatabaseInstance(ctx *Context, name string, args *DatabaseInstanceArgs, opts ...ResourceOption) (*DatabaseInstance, error)
    public DatabaseInstance(string name, DatabaseInstanceArgs? args = null, CustomResourceOptions? opts = null)
    public DatabaseInstance(String name, DatabaseInstanceArgs args)
    public DatabaseInstance(String name, DatabaseInstanceArgs args, CustomResourceOptions options)
    
    type: databricks:DatabaseInstance
    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 DatabaseInstanceArgs
    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 DatabaseInstanceArgs
    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 DatabaseInstanceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DatabaseInstanceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DatabaseInstanceArgs
    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 databaseInstanceResource = new Databricks.DatabaseInstance("databaseInstanceResource", new()
    {
        AdminPassword = "string",
        AdminRolename = "string",
        Capacity = "string",
        Name = "string",
        Stopped = false,
    });
    
    example, err := databricks.NewDatabaseInstance(ctx, "databaseInstanceResource", &databricks.DatabaseInstanceArgs{
    	AdminPassword: pulumi.String("string"),
    	AdminRolename: pulumi.String("string"),
    	Capacity:      pulumi.String("string"),
    	Name:          pulumi.String("string"),
    	Stopped:       pulumi.Bool(false),
    })
    
    var databaseInstanceResource = new DatabaseInstance("databaseInstanceResource", DatabaseInstanceArgs.builder()
        .adminPassword("string")
        .adminRolename("string")
        .capacity("string")
        .name("string")
        .stopped(false)
        .build());
    
    database_instance_resource = databricks.DatabaseInstance("databaseInstanceResource",
        admin_password="string",
        admin_rolename="string",
        capacity="string",
        name="string",
        stopped=False)
    
    const databaseInstanceResource = new databricks.DatabaseInstance("databaseInstanceResource", {
        adminPassword: "string",
        adminRolename: "string",
        capacity: "string",
        name: "string",
        stopped: false,
    });
    
    type: databricks:DatabaseInstance
    properties:
        adminPassword: string
        adminRolename: string
        capacity: string
        name: string
        stopped: false
    

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

    AdminPassword string
    Password for admin user to create. If not provided, no user will be created
    AdminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    Capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    Name string
    The name of the instance. This is the unique identifier for the instance
    Stopped bool
    Whether the instance is stopped
    AdminPassword string
    Password for admin user to create. If not provided, no user will be created
    AdminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    Capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    Name string
    The name of the instance. This is the unique identifier for the instance
    Stopped bool
    Whether the instance is stopped
    adminPassword String
    Password for admin user to create. If not provided, no user will be created
    adminRolename String
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity String
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    name String
    The name of the instance. This is the unique identifier for the instance
    stopped Boolean
    Whether the instance is stopped
    adminPassword string
    Password for admin user to create. If not provided, no user will be created
    adminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    name string
    The name of the instance. This is the unique identifier for the instance
    stopped boolean
    Whether the instance is stopped
    admin_password str
    Password for admin user to create. If not provided, no user will be created
    admin_rolename str
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity str
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    name str
    The name of the instance. This is the unique identifier for the instance
    stopped bool
    Whether the instance is stopped
    adminPassword String
    Password for admin user to create. If not provided, no user will be created
    adminRolename String
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity String
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    name String
    The name of the instance. This is the unique identifier for the instance
    stopped Boolean
    Whether the instance is stopped

    Outputs

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

    CreationTime string
    (string) - The timestamp when the instance was created
    Creator string
    (string) - The email of the creator of the instance
    Id string
    The provider-assigned unique ID for this managed resource.
    PgVersion string
    (string) - The version of Postgres running on the instance
    ReadWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    State string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    Uid string
    (string) - An immutable UUID identifier for the instance
    CreationTime string
    (string) - The timestamp when the instance was created
    Creator string
    (string) - The email of the creator of the instance
    Id string
    The provider-assigned unique ID for this managed resource.
    PgVersion string
    (string) - The version of Postgres running on the instance
    ReadWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    State string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    Uid string
    (string) - An immutable UUID identifier for the instance
    creationTime String
    (string) - The timestamp when the instance was created
    creator String
    (string) - The email of the creator of the instance
    id String
    The provider-assigned unique ID for this managed resource.
    pgVersion String
    (string) - The version of Postgres running on the instance
    readWriteDns String
    (string) - The DNS endpoint to connect to the instance for read+write access
    state String
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    uid String
    (string) - An immutable UUID identifier for the instance
    creationTime string
    (string) - The timestamp when the instance was created
    creator string
    (string) - The email of the creator of the instance
    id string
    The provider-assigned unique ID for this managed resource.
    pgVersion string
    (string) - The version of Postgres running on the instance
    readWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    state string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    uid string
    (string) - An immutable UUID identifier for the instance
    creation_time str
    (string) - The timestamp when the instance was created
    creator str
    (string) - The email of the creator of the instance
    id str
    The provider-assigned unique ID for this managed resource.
    pg_version str
    (string) - The version of Postgres running on the instance
    read_write_dns str
    (string) - The DNS endpoint to connect to the instance for read+write access
    state str
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    uid str
    (string) - An immutable UUID identifier for the instance
    creationTime String
    (string) - The timestamp when the instance was created
    creator String
    (string) - The email of the creator of the instance
    id String
    The provider-assigned unique ID for this managed resource.
    pgVersion String
    (string) - The version of Postgres running on the instance
    readWriteDns String
    (string) - The DNS endpoint to connect to the instance for read+write access
    state String
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    uid String
    (string) - An immutable UUID identifier for the instance

    Look up Existing DatabaseInstance Resource

    Get an existing DatabaseInstance 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?: DatabaseInstanceState, opts?: CustomResourceOptions): DatabaseInstance
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            admin_password: Optional[str] = None,
            admin_rolename: Optional[str] = None,
            capacity: Optional[str] = None,
            creation_time: Optional[str] = None,
            creator: Optional[str] = None,
            name: Optional[str] = None,
            pg_version: Optional[str] = None,
            read_write_dns: Optional[str] = None,
            state: Optional[str] = None,
            stopped: Optional[bool] = None,
            uid: Optional[str] = None) -> DatabaseInstance
    func GetDatabaseInstance(ctx *Context, name string, id IDInput, state *DatabaseInstanceState, opts ...ResourceOption) (*DatabaseInstance, error)
    public static DatabaseInstance Get(string name, Input<string> id, DatabaseInstanceState? state, CustomResourceOptions? opts = null)
    public static DatabaseInstance get(String name, Output<String> id, DatabaseInstanceState state, CustomResourceOptions options)
    resources:  _:    type: databricks:DatabaseInstance    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:
    AdminPassword string
    Password for admin user to create. If not provided, no user will be created
    AdminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    Capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    CreationTime string
    (string) - The timestamp when the instance was created
    Creator string
    (string) - The email of the creator of the instance
    Name string
    The name of the instance. This is the unique identifier for the instance
    PgVersion string
    (string) - The version of Postgres running on the instance
    ReadWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    State string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    Stopped bool
    Whether the instance is stopped
    Uid string
    (string) - An immutable UUID identifier for the instance
    AdminPassword string
    Password for admin user to create. If not provided, no user will be created
    AdminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    Capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    CreationTime string
    (string) - The timestamp when the instance was created
    Creator string
    (string) - The email of the creator of the instance
    Name string
    The name of the instance. This is the unique identifier for the instance
    PgVersion string
    (string) - The version of Postgres running on the instance
    ReadWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    State string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    Stopped bool
    Whether the instance is stopped
    Uid string
    (string) - An immutable UUID identifier for the instance
    adminPassword String
    Password for admin user to create. If not provided, no user will be created
    adminRolename String
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity String
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    creationTime String
    (string) - The timestamp when the instance was created
    creator String
    (string) - The email of the creator of the instance
    name String
    The name of the instance. This is the unique identifier for the instance
    pgVersion String
    (string) - The version of Postgres running on the instance
    readWriteDns String
    (string) - The DNS endpoint to connect to the instance for read+write access
    state String
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    stopped Boolean
    Whether the instance is stopped
    uid String
    (string) - An immutable UUID identifier for the instance
    adminPassword string
    Password for admin user to create. If not provided, no user will be created
    adminRolename string
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity string
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    creationTime string
    (string) - The timestamp when the instance was created
    creator string
    (string) - The email of the creator of the instance
    name string
    The name of the instance. This is the unique identifier for the instance
    pgVersion string
    (string) - The version of Postgres running on the instance
    readWriteDns string
    (string) - The DNS endpoint to connect to the instance for read+write access
    state string
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    stopped boolean
    Whether the instance is stopped
    uid string
    (string) - An immutable UUID identifier for the instance
    admin_password str
    Password for admin user to create. If not provided, no user will be created
    admin_rolename str
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity str
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    creation_time str
    (string) - The timestamp when the instance was created
    creator str
    (string) - The email of the creator of the instance
    name str
    The name of the instance. This is the unique identifier for the instance
    pg_version str
    (string) - The version of Postgres running on the instance
    read_write_dns str
    (string) - The DNS endpoint to connect to the instance for read+write access
    state str
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    stopped bool
    Whether the instance is stopped
    uid str
    (string) - An immutable UUID identifier for the instance
    adminPassword String
    Password for admin user to create. If not provided, no user will be created
    adminRolename String
    Name of the admin role for the instance. If not provided, defaults to 'databricks_admin'
    capacity String
    The sku of the instance. Valid values are "CU_1", "CU_2", "CU_4"
    creationTime String
    (string) - The timestamp when the instance was created
    creator String
    (string) - The email of the creator of the instance
    name String
    The name of the instance. This is the unique identifier for the instance
    pgVersion String
    (string) - The version of Postgres running on the instance
    readWriteDns String
    (string) - The DNS endpoint to connect to the instance for read+write access
    state String
    (string) - The current state of the instance. Possible values are: AVAILABLE, DELETING, FAILING_OVER, STARTING, STOPPED, UPDATING
    stopped Boolean
    Whether the instance is stopped
    uid String
    (string) - An immutable UUID identifier for the instance

    Package Details

    Repository
    databricks pulumi/pulumi-databricks
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the databricks Terraform Provider.
    databricks logo
    Databricks v1.71.0 published on Monday, Jun 9, 2025 by Pulumi