@pulumi/databricks
Version:
A Pulumi package for creating and managing databricks cloud resources.
138 lines (137 loc) • 6.45 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "./types/input";
import * as outputs from "./types/output";
/**
* > This resource can be used with an account or workspace-level provider.
*
* Optionally, each databricks.Metastore can have a default databricks.StorageCredential defined as `databricks.MetastoreDataAccess`. This will be used by Unity Catalog to access data in the root storage location if defined.
*
* ## Example Usage
*
* For AWS
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as databricks from "@pulumi/databricks";
*
* const _this = new databricks.Metastore("this", {
* name: "primary",
* storageRoot: `s3://${metastore.id}/metastore`,
* owner: "uc admins",
* region: "us-east-1",
* forceDestroy: true,
* });
* const thisMetastoreDataAccess = new databricks.MetastoreDataAccess("this", {
* metastoreId: _this.id,
* name: metastoreDataAccess.name,
* awsIamRole: {
* roleArn: metastoreDataAccess.arn,
* },
* isDefault: true,
* });
* ```
*
* For Azure using managed identity as credential (recommended)
*
* ## Import
*
* This resource can be imported by combination of metastore id and the data access name.
*
* bash
*
* ```sh
* $ pulumi import databricks:index/metastoreDataAccess:MetastoreDataAccess this '<metastore_id>|<name>'
* ```
*/
export declare class MetastoreDataAccess extends pulumi.CustomResource {
/**
* Get an existing MetastoreDataAccess resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: MetastoreDataAccessState, opts?: pulumi.CustomResourceOptions): MetastoreDataAccess;
/**
* Returns true if the given object is an instance of MetastoreDataAccess. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is MetastoreDataAccess;
readonly awsIamRole: pulumi.Output<outputs.MetastoreDataAccessAwsIamRole | undefined>;
readonly azureManagedIdentity: pulumi.Output<outputs.MetastoreDataAccessAzureManagedIdentity | undefined>;
readonly azureServicePrincipal: pulumi.Output<outputs.MetastoreDataAccessAzureServicePrincipal | undefined>;
readonly cloudflareApiToken: pulumi.Output<outputs.MetastoreDataAccessCloudflareApiToken | undefined>;
readonly comment: pulumi.Output<string | undefined>;
readonly databricksGcpServiceAccount: pulumi.Output<outputs.MetastoreDataAccessDatabricksGcpServiceAccount>;
readonly forceDestroy: pulumi.Output<boolean | undefined>;
readonly forceUpdate: pulumi.Output<boolean | undefined>;
readonly gcpServiceAccountKey: pulumi.Output<outputs.MetastoreDataAccessGcpServiceAccountKey | undefined>;
/**
* whether to set this credential as the default for the metastore. In practice, this should always be true.
*/
readonly isDefault: pulumi.Output<boolean | undefined>;
readonly isolationMode: pulumi.Output<string>;
readonly metastoreId: pulumi.Output<string>;
readonly name: pulumi.Output<string>;
readonly owner: pulumi.Output<string>;
readonly readOnly: pulumi.Output<boolean | undefined>;
readonly skipValidation: pulumi.Output<boolean | undefined>;
/**
* Create a MetastoreDataAccess resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args?: MetastoreDataAccessArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering MetastoreDataAccess resources.
*/
export interface MetastoreDataAccessState {
awsIamRole?: pulumi.Input<inputs.MetastoreDataAccessAwsIamRole>;
azureManagedIdentity?: pulumi.Input<inputs.MetastoreDataAccessAzureManagedIdentity>;
azureServicePrincipal?: pulumi.Input<inputs.MetastoreDataAccessAzureServicePrincipal>;
cloudflareApiToken?: pulumi.Input<inputs.MetastoreDataAccessCloudflareApiToken>;
comment?: pulumi.Input<string>;
databricksGcpServiceAccount?: pulumi.Input<inputs.MetastoreDataAccessDatabricksGcpServiceAccount>;
forceDestroy?: pulumi.Input<boolean>;
forceUpdate?: pulumi.Input<boolean>;
gcpServiceAccountKey?: pulumi.Input<inputs.MetastoreDataAccessGcpServiceAccountKey>;
/**
* whether to set this credential as the default for the metastore. In practice, this should always be true.
*/
isDefault?: pulumi.Input<boolean>;
isolationMode?: pulumi.Input<string>;
metastoreId?: pulumi.Input<string>;
name?: pulumi.Input<string>;
owner?: pulumi.Input<string>;
readOnly?: pulumi.Input<boolean>;
skipValidation?: pulumi.Input<boolean>;
}
/**
* The set of arguments for constructing a MetastoreDataAccess resource.
*/
export interface MetastoreDataAccessArgs {
awsIamRole?: pulumi.Input<inputs.MetastoreDataAccessAwsIamRole>;
azureManagedIdentity?: pulumi.Input<inputs.MetastoreDataAccessAzureManagedIdentity>;
azureServicePrincipal?: pulumi.Input<inputs.MetastoreDataAccessAzureServicePrincipal>;
cloudflareApiToken?: pulumi.Input<inputs.MetastoreDataAccessCloudflareApiToken>;
comment?: pulumi.Input<string>;
databricksGcpServiceAccount?: pulumi.Input<inputs.MetastoreDataAccessDatabricksGcpServiceAccount>;
forceDestroy?: pulumi.Input<boolean>;
forceUpdate?: pulumi.Input<boolean>;
gcpServiceAccountKey?: pulumi.Input<inputs.MetastoreDataAccessGcpServiceAccountKey>;
/**
* whether to set this credential as the default for the metastore. In practice, this should always be true.
*/
isDefault?: pulumi.Input<boolean>;
isolationMode?: pulumi.Input<string>;
metastoreId?: pulumi.Input<string>;
name?: pulumi.Input<string>;
owner?: pulumi.Input<string>;
readOnly?: pulumi.Input<boolean>;
skipValidation?: pulumi.Input<boolean>;
}