storage
Creates, updates, deletes, gets or lists a storage resource.
Overview
| Name | storage |
| Type | Resource |
| Id | databricks_account.provisioning.storage |
Fields
The following fields are returned by SELECT queries:
- storage_get
- storage_list
| Name | Datatype | Description |
|---|---|---|
account_id | string | |
storage_configuration_id | string | Databricks storage configuration ID. |
storage_configuration_name | string | The human-readable name of the storage configuration. |
creation_time | integer | Time in epoch milliseconds when the storage configuration was created. |
role_arn | string | Optional IAM role that is used to access the workspace catalog which is created during workspace creation for UC by Default. If a storage configuration with this field populated is used to create a workspace, then a workspace catalog is created together with the workspace. The workspace catalog shares the root bucket with internal workspace storage (including DBFS root) but uses a dedicated bucket path prefix. |
root_bucket_info | object | The root bucket information for the storage configuration. |
| Name | Datatype | Description |
|---|---|---|
account_id | string | |
storage_configuration_id | string | Databricks storage configuration ID. |
storage_configuration_name | string | The human-readable name of the storage configuration. |
creation_time | integer | Time in epoch milliseconds when the storage configuration was created. |
role_arn | string | Optional IAM role that is used to access the workspace catalog which is created during workspace creation for UC by Default. If a storage configuration with this field populated is used to create a workspace, then a workspace catalog is created together with the workspace. The workspace catalog shares the root bucket with internal workspace storage (including DBFS root) but uses a dedicated bucket path prefix. |
root_bucket_info | object | The root bucket information for the storage configuration. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
storage_get | select | account_id, storage_configuration_id | Gets a Databricks storage configuration for an account, both specified by ID. | |
storage_list | select | account_id | Lists Databricks storage configurations for an account, specified by ID. | |
storage_create | insert | account_id, storage_configuration_name, root_bucket_info | Creates a Databricks storage configuration for an account. | |
storage_delete | delete | account_id, storage_configuration_id | Deletes a Databricks storage configuration. You cannot delete a storage configuration that is |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
account_id | string | |
storage_configuration_id | string |
SELECT examples
- storage_get
- storage_list
Gets a Databricks storage configuration for an account, both specified by ID.
SELECT
account_id,
storage_configuration_id,
storage_configuration_name,
creation_time,
role_arn,
root_bucket_info
FROM databricks_account.provisioning.storage
WHERE account_id = '{{ account_id }}' -- required
AND storage_configuration_id = '{{ storage_configuration_id }}' -- required
;
Lists Databricks storage configurations for an account, specified by ID.
SELECT
account_id,
storage_configuration_id,
storage_configuration_name,
creation_time,
role_arn,
root_bucket_info
FROM databricks_account.provisioning.storage
WHERE account_id = '{{ account_id }}' -- required
;
INSERT examples
- storage_create
- Manifest
Creates a Databricks storage configuration for an account.
INSERT INTO databricks_account.provisioning.storage (
storage_configuration_name,
root_bucket_info,
role_arn,
account_id
)
SELECT
'{{ storage_configuration_name }}' /* required */,
'{{ root_bucket_info }}' /* required */,
'{{ role_arn }}',
'{{ account_id }}'
RETURNING
account_id,
storage_configuration_id,
storage_configuration_name,
creation_time,
role_arn,
root_bucket_info
;
# Description fields are for documentation purposes
- name: storage
props:
- name: account_id
value: "{{ account_id }}"
description: Required parameter for the storage resource.
- name: storage_configuration_name
value: "{{ storage_configuration_name }}"
description: |
The human-readable name of the storage configuration.
- name: root_bucket_info
description: |
Root S3 bucket information.
value:
bucket_name: "{{ bucket_name }}"
- name: role_arn
value: "{{ role_arn }}"
description: |
Optional IAM role that is used to access the workspace catalog which is created during workspace creation for UC by Default. If a storage configuration with this field populated is used to create a workspace, then a workspace catalog is created together with the workspace. The workspace catalog shares the root bucket with internal workspace storage (including DBFS root) but uses a dedicated bucket path prefix.
DELETE examples
- storage_delete
Deletes a Databricks storage configuration. You cannot delete a storage configuration that is
DELETE FROM databricks_account.provisioning.storage
WHERE account_id = '{{ account_id }}' --required
AND storage_configuration_id = '{{ storage_configuration_id }}' --required
;