UNPKG

@pulumi/databricks

Version:

A Pulumi package for creating and managing databricks cloud resources.

206 lines (205 loc) 8.12 kB
import * as pulumi from "@pulumi/pulumi"; /** * Retrieves information about databricks_service_principal. * * > This data source can be used with an account or workspace-level provider. * * ## Example Usage * * Adding service principal `11111111-2222-3333-4444-555666777888` to administrative group * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as databricks from "@pulumi/databricks"; * * const admins = databricks.getGroup({ * displayName: "admins", * }); * const spn = databricks.getServicePrincipal({ * applicationId: "11111111-2222-3333-4444-555666777888", * }); * const myMemberA = new databricks.GroupMember("my_member_a", { * groupId: admins.then(admins => admins.id), * memberId: spn.then(spn => spn.id), * }); * ``` * * ## Related Resources * * The following resources are used in the same context: * * - End to end workspace management guide. * - databricks.getCurrentUser data to retrieve information about databricks.User or databricks_service_principal, that is calling Databricks REST API. * - databricks.Group to manage [Account-level](https://docs.databricks.com/aws/en/admin/users-groups/groups) or [Workspace-level](https://docs.databricks.com/aws/en/admin/users-groups/workspace-local-groups) groups. * - databricks.Group data to retrieve information about databricks.Group members, entitlements and instance profiles. * - databricks.GroupInstanceProfile to attach databricks.InstanceProfile (AWS) to databricks_group. * - databricks.GroupMember to attach users and groups as group members. * - databricks.Permissions to manage [access control](https://docs.databricks.com/security/access-control/index.html) in Databricks workspace. * - databricksService principal to manage service principals */ export declare function getServicePrincipal(args?: GetServicePrincipalArgs, opts?: pulumi.InvokeOptions): Promise<GetServicePrincipalResult>; /** * A collection of arguments for invoking getServicePrincipal. */ export interface GetServicePrincipalArgs { /** * identifier for use in databricks_access_control_rule_set, e.g. `servicePrincipals/00000000-0000-0000-0000-000000000000`. */ aclPrincipalId?: string; /** * Whether service principal is active or not. */ active?: boolean; /** * Application ID of the service principal. The service principal must exist before this resource can be retrieved. */ applicationId?: string; /** * Exact display name of the service principal. The service principal must exist before this resource can be retrieved. In case if there are several service principals with the same name, an error is thrown. */ displayName?: string; /** * ID of the service principal in an external identity provider. */ externalId?: string; /** * Home folder of the service principal, e.g. `/Users/11111111-2222-3333-4444-555666777888`. */ home?: string; /** * The id of the service principal (SCIM ID). */ id?: string; /** * Repos location of the service principal, e.g. `/Repos/11111111-2222-3333-4444-555666777888`. */ repos?: string; /** * Unique SCIM ID for a service principal in the Databricks workspace. The service principal must exist before this resource can be retrieved. */ scimId?: string; spId?: string; } /** * A collection of values returned by getServicePrincipal. */ export interface GetServicePrincipalResult { /** * identifier for use in databricks_access_control_rule_set, e.g. `servicePrincipals/00000000-0000-0000-0000-000000000000`. */ readonly aclPrincipalId: string; /** * Whether service principal is active or not. */ readonly active: boolean; /** * Application ID of the service principal. */ readonly applicationId: string; /** * Display name of the service principal, e.g. `Foo SPN`. */ readonly displayName: string; /** * ID of the service principal in an external identity provider. */ readonly externalId: string; /** * Home folder of the service principal, e.g. `/Users/11111111-2222-3333-4444-555666777888`. */ readonly home: string; /** * The id of the service principal (SCIM ID). */ readonly id: string; /** * Repos location of the service principal, e.g. `/Repos/11111111-2222-3333-4444-555666777888`. */ readonly repos: string; /** * same as `id`. */ readonly scimId: string; readonly spId: string; } /** * Retrieves information about databricks_service_principal. * * > This data source can be used with an account or workspace-level provider. * * ## Example Usage * * Adding service principal `11111111-2222-3333-4444-555666777888` to administrative group * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as databricks from "@pulumi/databricks"; * * const admins = databricks.getGroup({ * displayName: "admins", * }); * const spn = databricks.getServicePrincipal({ * applicationId: "11111111-2222-3333-4444-555666777888", * }); * const myMemberA = new databricks.GroupMember("my_member_a", { * groupId: admins.then(admins => admins.id), * memberId: spn.then(spn => spn.id), * }); * ``` * * ## Related Resources * * The following resources are used in the same context: * * - End to end workspace management guide. * - databricks.getCurrentUser data to retrieve information about databricks.User or databricks_service_principal, that is calling Databricks REST API. * - databricks.Group to manage [Account-level](https://docs.databricks.com/aws/en/admin/users-groups/groups) or [Workspace-level](https://docs.databricks.com/aws/en/admin/users-groups/workspace-local-groups) groups. * - databricks.Group data to retrieve information about databricks.Group members, entitlements and instance profiles. * - databricks.GroupInstanceProfile to attach databricks.InstanceProfile (AWS) to databricks_group. * - databricks.GroupMember to attach users and groups as group members. * - databricks.Permissions to manage [access control](https://docs.databricks.com/security/access-control/index.html) in Databricks workspace. * - databricksService principal to manage service principals */ export declare function getServicePrincipalOutput(args?: GetServicePrincipalOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetServicePrincipalResult>; /** * A collection of arguments for invoking getServicePrincipal. */ export interface GetServicePrincipalOutputArgs { /** * identifier for use in databricks_access_control_rule_set, e.g. `servicePrincipals/00000000-0000-0000-0000-000000000000`. */ aclPrincipalId?: pulumi.Input<string>; /** * Whether service principal is active or not. */ active?: pulumi.Input<boolean>; /** * Application ID of the service principal. The service principal must exist before this resource can be retrieved. */ applicationId?: pulumi.Input<string>; /** * Exact display name of the service principal. The service principal must exist before this resource can be retrieved. In case if there are several service principals with the same name, an error is thrown. */ displayName?: pulumi.Input<string>; /** * ID of the service principal in an external identity provider. */ externalId?: pulumi.Input<string>; /** * Home folder of the service principal, e.g. `/Users/11111111-2222-3333-4444-555666777888`. */ home?: pulumi.Input<string>; /** * The id of the service principal (SCIM ID). */ id?: pulumi.Input<string>; /** * Repos location of the service principal, e.g. `/Repos/11111111-2222-3333-4444-555666777888`. */ repos?: pulumi.Input<string>; /** * Unique SCIM ID for a service principal in the Databricks workspace. The service principal must exist before this resource can be retrieved. */ scimId?: pulumi.Input<string>; spId?: pulumi.Input<string>; }