Class RotationScheduleOptions
- Namespace
- Amazon.CDK.AWS.SecretsManager
- Assembly
- Amazon.CDK.AWS.SecretsManager.dll
Options to add a rotation schedule to a secret.
public class RotationScheduleOptions : IRotationScheduleOptions
- Inheritance
-
RotationScheduleOptions
- Implements
- Inherited Members
Examples
using Amazon.CDK.AWS.Lambda;
Function fn;
var secret = new Secret(this, "Secret");
secret.AddRotationSchedule("RotationSchedule", new RotationScheduleOptions {
RotationLambda = fn,
AutomaticallyAfter = Duration.Days(15)
});
Remarks
ExampleMetadata: infused
Constructors
RotationScheduleOptions()
public RotationScheduleOptions()
Properties
AutomaticallyAfter
Specifies the number of days after the previous rotation before Secrets Manager triggers the next automatic rotation.
public Duration? AutomaticallyAfter { get; set; }
Property Value
- Duration
Remarks
A value of zero will disable automatic rotation - Duration.days(0).
Default: Duration.days(30)
HostedRotation
Hosted rotation.
public HostedRotation? HostedRotation { get; set; }
Property Value
Remarks
Default: - either rotationLambda or hostedRotation must be specified
RotationLambda
A Lambda function that can rotate the secret.
public IFunction? RotationLambda { get; set; }
Property Value
- IFunction
Remarks
Default: - either rotationLambda or hostedRotation must be specified