how to Rotate secrets for aurora instance ,ysql/postgresql

0

How to rotate secrets(credentials) for Aurora mysql.postgresql using cloudformation. In the documentation, i see only its specified for RDS databases. https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-secretsmanager-rotationschedule.html

AWS
已提问 6 个月前180 查看次数
1 回答
0

Hi,

Have a look the complete CFN teample at https://github.com/aws-samples/aws-aurora-cloudformation-samples/blob/master/cftemplates/Aurora-Postgres-DB-Cluster.yml

It contains the full details for all resources. The section of interest for you is:

AuroraSecretRotationSchedule:
    Condition: IsNotUseDBSnapshot
    Type: AWS::SecretsManager::RotationSchedule
    DependsOn:
      - SecretAuroraClusterAttachment
      - AuroraDBFirstInstance
    Properties:
      SecretId: !Ref AuroraMasterSecret
      RotationLambdaARN: !GetAtt CreateSecretRotationLambdaFnTrigger.SecretRotationLambdaARN
      RotationRules:
        AutomaticallyAfterDays: 30

Best,

Didier

profile pictureAWS
专家
已回答 6 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则