Skip to content

User

laktory.models.resources.databricks.User ¤

Bases: UserBase

Databricks user

Examples:

import io

from laktory import models

user_yaml = '''
user_name: john.doe@okube.ai
display_name: John Doe
group_ids:
- ${resources.group-role-engineer.id}
- ${resources.group-domain-finance.id}
roles:
- account_admin
'''
user = models.resources.databricks.User.model_validate_yaml(io.StringIO(user_yaml))
References
BASE DESCRIPTION
acl_principal_id

identifier for use in databricks_access_control_rule_set, e.g. users/mr.foo@example.com

TYPE: str | None | VariableType DEFAULT: None

active

Either user is active or not. True by default, but can be set to false in case of user deactivation with preserving user assets

TYPE: bool | None | VariableType DEFAULT: None

allow_cluster_create

Allow the user to have cluster create privileges. Defaults to false. More fine grained permissions could be assigned with databricks_permissions and cluster_id argument. Everyone without allow_cluster_create argument set, but with permission to use Cluster Policy would be able to create clusters, but within boundaries of that specific policy

TYPE: bool | None | VariableType DEFAULT: None

allow_instance_pool_create

Allow the user to have instance pool create privileges. Defaults to false. More fine grained permissions could be assigned with databricks_permissions and instance_pool_id argument

TYPE: bool | None | VariableType DEFAULT: None

api

Specifies whether to use account-level or workspace-level API. Valid values are account and workspace. When not set, the API level is inferred from the provider host

TYPE: str | None | VariableType DEFAULT: None

databricks_sql_access

This is a field to allow the user to have access to Databricks SQL UI, Databricks One and through databricks_sql_endpoint

TYPE: bool | None | VariableType DEFAULT: None

disable_as_user_deletion

Deactivate the user when deleting the resource, rather than deleting the user entirely. Defaults to true when the provider is configured at the account-level and false when configured at the workspace-level. This flag is exclusive to force_delete_repos and force_delete_home_dir flags

TYPE: bool | None | VariableType DEFAULT: None

display_name

This is an alias for the username that can be the full name of the user

TYPE: str | None | VariableType DEFAULT: None

external_id

ID of the user in an external identity provider

TYPE: str | None | VariableType DEFAULT: None

force

Ignore cannot create user: User with username X already exists errors and implicitly import the specific user into Terraform state, enforcing entitlements defined in the instance of resource. This functionality is experimental and is designed to simplify corner cases, like Azure Active Directory synchronisation

TYPE: bool | None | VariableType DEFAULT: None

force_delete_home_dir

This flag determines whether the user's home directory is deleted when the user is deleted. It will have not impact when in the accounts SCIM API. False by default

TYPE: bool | None | VariableType DEFAULT: None

force_delete_repos

This flag determines whether the user's repo directory is deleted when the user is deleted. It will have no impact when in the accounts SCIM API. False by default

TYPE: bool | None | VariableType DEFAULT: None

home

Home folder of the user, e.g. /Users/mr.foo@example.com

TYPE: str | None | VariableType DEFAULT: None

repos

Personal Repos location of the user, e.g. /Repos/mr.foo@example.com

TYPE: str | None | VariableType DEFAULT: None

user_name

This is the username of the given user and will be their form of access and identity. Provided username will be converted to lower case if it contains upper case characters

TYPE: str | VariableType

workspace_access

This is a field to allow the user to have access to a Databricks Workspace UI and Databricks One

TYPE: bool | None | VariableType DEFAULT: None

workspace_consume

This is a field to allow the user to have access only to Databricks One. Couldn't be used with workspace_access or databricks_sql_access

TYPE: bool | None | VariableType DEFAULT: None

LAKTORY DESCRIPTION
group_ids

List of the group ids that the user should be member of.

TYPE: list[str | VariableType] | VariableType DEFAULT: []

roles

List of roles assigned to the user e.g. ('account_admin')

TYPE: list[str | VariableType] | VariableType DEFAULT: []

workspace_permission_assignments

TYPE: list[MwsPermissionAssignment | VariableType] | VariableType DEFAULT: None

ATTRIBUTE DESCRIPTION
additional_core_resources
  • user roles

TYPE: list

additional_core_resources property ¤

  • user roles
  • user group members

laktory.models.resources.databricks.user.UserLookup ¤

Bases: ResourceLookup

PARAMETER DESCRIPTION
user_id

ID of the user

TYPE: int | str | VariableType DEFAULT: None

user_name

User name of the user. The user must exist before this resource can be planned. Argument only supported by Terraform IaC backend.

TYPE: str | VariableType DEFAULT: None