We recommend new projects start with resources from the AWS provider.
aws-native.secretsmanager.RotationSchedule
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
Resource Type definition for AWS::SecretsManager::RotationSchedule
Create RotationSchedule Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new RotationSchedule(name: string, args: RotationScheduleArgs, opts?: CustomResourceOptions);
@overload
def RotationSchedule(resource_name: str,
args: RotationScheduleArgs,
opts: Optional[ResourceOptions] = None)
@overload
def RotationSchedule(resource_name: str,
opts: Optional[ResourceOptions] = None,
secret_id: Optional[str] = None,
hosted_rotation_lambda: Optional[RotationScheduleHostedRotationLambdaArgs] = None,
rotate_immediately_on_update: Optional[bool] = None,
rotation_lambda_arn: Optional[str] = None,
rotation_rules: Optional[RotationScheduleRotationRulesArgs] = None)
func NewRotationSchedule(ctx *Context, name string, args RotationScheduleArgs, opts ...ResourceOption) (*RotationSchedule, error)
public RotationSchedule(string name, RotationScheduleArgs args, CustomResourceOptions? opts = null)
public RotationSchedule(String name, RotationScheduleArgs args)
public RotationSchedule(String name, RotationScheduleArgs args, CustomResourceOptions options)
type: aws-native:secretsmanager:RotationSchedule
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args RotationScheduleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args RotationScheduleArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args RotationScheduleArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RotationScheduleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args RotationScheduleArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
RotationSchedule Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The RotationSchedule resource accepts the following input properties:
- Secret
Id string - The ARN or name of the secret to rotate.
- Hosted
Rotation Pulumi.Lambda Aws Native. Secrets Manager. Inputs. Rotation Schedule Hosted Rotation Lambda - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- Rotate
Immediately boolOn Update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- Rotation
Lambda stringArn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- Rotation
Rules Pulumi.Aws Native. Secrets Manager. Inputs. Rotation Schedule Rotation Rules - A structure that defines the rotation configuration for this secret.
- Secret
Id string - The ARN or name of the secret to rotate.
- Hosted
Rotation RotationLambda Schedule Hosted Rotation Lambda Args - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- Rotate
Immediately boolOn Update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- Rotation
Lambda stringArn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- Rotation
Rules RotationSchedule Rotation Rules Args - A structure that defines the rotation configuration for this secret.
- secret
Id String - The ARN or name of the secret to rotate.
- hosted
Rotation RotationLambda Schedule Hosted Rotation Lambda - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- rotate
Immediately BooleanOn Update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- rotation
Lambda StringArn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- rotation
Rules RotationSchedule Rotation Rules - A structure that defines the rotation configuration for this secret.
- secret
Id string - The ARN or name of the secret to rotate.
- hosted
Rotation RotationLambda Schedule Hosted Rotation Lambda - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- rotate
Immediately booleanOn Update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- rotation
Lambda stringArn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- rotation
Rules RotationSchedule Rotation Rules - A structure that defines the rotation configuration for this secret.
- secret_
id str - The ARN or name of the secret to rotate.
- hosted_
rotation_ Rotationlambda Schedule Hosted Rotation Lambda Args - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- rotate_
immediately_ boolon_ update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- rotation_
lambda_ strarn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- rotation_
rules RotationSchedule Rotation Rules Args - A structure that defines the rotation configuration for this secret.
- secret
Id String - The ARN or name of the secret to rotate.
- hosted
Rotation Property MapLambda - Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead.
- rotate
Immediately BooleanOn Update - Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window.
- rotation
Lambda StringArn - The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function.
- rotation
Rules Property Map - A structure that defines the rotation configuration for this secret.
Outputs
All input properties are implicitly available as output properties. Additionally, the RotationSchedule resource produces the following output properties:
Supporting Types
RotationScheduleHostedRotationLambda, RotationScheduleHostedRotationLambdaArgs
- Rotation
Type string - The type of rotation template to use
- Exclude
Characters string - A string of the characters that you don't want in the password.
- Kms
Key stringArn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- Master
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- Master
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- Rotation
Lambda stringName - The name of the Lambda rotation function.
- Runtime string
- The python runtime associated with the Lambda function
- Superuser
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- Superuser
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- Vpc
Security stringGroup Ids - A comma-separated list of security group IDs applied to the target database.
- Vpc
Subnet stringIds - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
- Rotation
Type string - The type of rotation template to use
- Exclude
Characters string - A string of the characters that you don't want in the password.
- Kms
Key stringArn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- Master
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- Master
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- Rotation
Lambda stringName - The name of the Lambda rotation function.
- Runtime string
- The python runtime associated with the Lambda function
- Superuser
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- Superuser
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- Vpc
Security stringGroup Ids - A comma-separated list of security group IDs applied to the target database.
- Vpc
Subnet stringIds - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
- rotation
Type String - The type of rotation template to use
- exclude
Characters String - A string of the characters that you don't want in the password.
- kms
Key StringArn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- master
Secret StringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- master
Secret StringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- rotation
Lambda StringName - The name of the Lambda rotation function.
- runtime String
- The python runtime associated with the Lambda function
- superuser
Secret StringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- superuser
Secret StringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- vpc
Security StringGroup Ids - A comma-separated list of security group IDs applied to the target database.
- vpc
Subnet StringIds - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
- rotation
Type string - The type of rotation template to use
- exclude
Characters string - A string of the characters that you don't want in the password.
- kms
Key stringArn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- master
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- master
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- rotation
Lambda stringName - The name of the Lambda rotation function.
- runtime string
- The python runtime associated with the Lambda function
- superuser
Secret stringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- superuser
Secret stringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- vpc
Security stringGroup Ids - A comma-separated list of security group IDs applied to the target database.
- vpc
Subnet stringIds - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
- rotation_
type str - The type of rotation template to use
- exclude_
characters str - A string of the characters that you don't want in the password.
- kms_
key_ strarn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- master_
secret_ strarn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- master_
secret_ strkms_ key_ arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- rotation_
lambda_ strname - The name of the Lambda rotation function.
- runtime str
- The python runtime associated with the Lambda function
- superuser_
secret_ strarn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- superuser_
secret_ strkms_ key_ arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- vpc_
security_ strgroup_ ids - A comma-separated list of security group IDs applied to the target database.
- vpc_
subnet_ strids - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
- rotation
Type String - The type of rotation template to use
- exclude
Characters String - A string of the characters that you don't want in the password.
- kms
Key StringArn - The ARN of the KMS key that Secrets Manager uses to encrypt the secret. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If aws/secretsmanager doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value.
- master
Secret StringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- master
Secret StringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- rotation
Lambda StringName - The name of the Lambda rotation function.
- runtime String
- The python runtime associated with the Lambda function
- superuser
Secret StringArn - The ARN of the secret that contains superuser credentials, if you use the alternating users rotation strategy. CloudFormation grants the execution role for the Lambda rotation function GetSecretValue permission to the secret in this property.
- superuser
Secret StringKms Key Arn - The ARN of the KMS key that Secrets Manager used to encrypt the superuser secret, if you use the alternating users strategy and the superuser secret is encrypted with a customer managed key. You don't need to specify this property if the superuser secret is encrypted using the key aws/secretsmanager. CloudFormation grants the execution role for the Lambda rotation function Decrypt, DescribeKey, and GenerateDataKey permission to the key in this property.
- vpc
Security StringGroup Ids - A comma-separated list of security group IDs applied to the target database.
- vpc
Subnet StringIds - A comma separated list of VPC subnet IDs of the target database network. The Lambda rotation function is in the same subnet group.
RotationScheduleRotationRules, RotationScheduleRotationRulesArgs
- Automatically
After intDays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- Duration string
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- Schedule
Expression string - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
- Automatically
After intDays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- Duration string
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- Schedule
Expression string - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
- automatically
After IntegerDays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- duration String
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- schedule
Expression String - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
- automatically
After numberDays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- duration string
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- schedule
Expression string - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
- automatically_
after_ intdays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- duration str
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- schedule_
expression str - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
- automatically
After NumberDays - The number of days between automatic scheduled rotations of the secret. You can use this value to check that your secret meets your compliance guidelines for how often secrets must be rotated.
- duration String
- The length of the rotation window in hours, for example 3h for a three hour window. Secrets Manager rotates your secret at any time during this window. The window must not extend into the next rotation window or the next UTC day. The window starts according to the ScheduleExpression. If you don't specify a Duration, for a ScheduleExpression in hours, the window automatically closes after one hour. For a ScheduleExpression in days, the window automatically closes at the end of the UTC day.
- schedule
Expression String - A cron() or rate() expression that defines the schedule for rotating your secret. Secrets Manager rotation schedules use UTC time zone.
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.