UserProps

class aws_cdk.aws_redshift_alpha.UserProps(*, cluster, database_name, admin_user=None, encryption_key=None, exclude_characters=None, removal_policy=None, username=None)

Bases: DatabaseOptions

(experimental) Properties for configuring a Redshift user.

Parameters:
  • cluster (ICluster) – (experimental) The cluster containing the database.

  • database_name (str) – (experimental) The name of the database.

  • admin_user (Optional[ISecret]) – (experimental) The secret containing credentials to a Redshift user with administrator privileges. Secret JSON schema: { username: string; password: string }. Default: - the admin secret is taken from the cluster

  • encryption_key (Optional[IKey]) – (experimental) KMS key to encrypt the generated secret. Default: - the default AWS managed key is used

  • exclude_characters (Optional[str]) – (experimental) Characters to not include in the generated password. Default: ‘”@/\ ‘’

  • removal_policy (Optional[RemovalPolicy]) – (experimental) The policy to apply when this resource is removed from the application. Default: cdk.RemovalPolicy.Destroy

  • username (Optional[str]) – (experimental) The name of the user. For valid values, see: https://docs.aws.amazon.com/redshift/latest/dg/r_names.html Default: - a name is generated

Stability:

experimental

ExampleMetadata:

fixture=cluster infused

Example:

user = User(self, "User",
    cluster=cluster,
    database_name="databaseName"
)
cluster.add_rotation_multi_user("MultiUserRotation",
    secret=user.secret
)

Attributes

admin_user

(experimental) The secret containing credentials to a Redshift user with administrator privileges.

Secret JSON schema: { username: string; password: string }.

Default:
  • the admin secret is taken from the cluster

Stability:

experimental

cluster

(experimental) The cluster containing the database.

Stability:

experimental

database_name

(experimental) The name of the database.

Stability:

experimental

encryption_key

(experimental) KMS key to encrypt the generated secret.

Default:
  • the default AWS managed key is used

Stability:

experimental

exclude_characters

(experimental) Characters to not include in the generated password.

Default:

‘”@/\ ‘’

Stability:

experimental

removal_policy

(experimental) The policy to apply when this resource is removed from the application.

Default:

cdk.RemovalPolicy.Destroy

Stability:

experimental

username

(experimental) The name of the user.

For valid values, see: https://docs.aws.amazon.com/redshift/latest/dg/r_names.html

Default:
  • a name is generated

Stability:

experimental