aws / aws-cdk

The AWS Cloud Development Kit is a framework for defining cloud infrastructure in code
https://aws.amazon.com/cdk
Apache License 2.0
11.68k stars 3.93k forks source link

AWS::RDS::DBCluster Password management with Amazon Aurora and AWS Secrets Manager #29239

Open csotomon opened 8 months ago

csotomon commented 8 months ago

Describe the feature

Amazon Aurora integrates with Secrets Manager to manage master user passwords for your DB clusters.

This feature is implemented on the aws_cdk.aws_rds.CfnDBCluster construct but not on the aws_cdk.aws_rds.DatabaseCluster construct.

At the moment unique way to activated is running a cluster.node.default_child.add_override('Properties.ManageMasterUserPassword', True) instruction.

Use Case

I need to activate the password management for an aurora Serverless V2 database using secret manager.

Proposed Solution

add this parameter in the aws_cdk.aws_rds.DatabaseCluster class constructor.

Other Information

No response

Acknowledgements

CDK version used

2.129.0

Environment details (OS name and version, etc.)

linux ubuntu

juinquok commented 8 months ago

We've got a use case for this too, happy to help implement this if its okay with the team

pahud commented 8 months ago

Yes I think we could expose that to the L2 props. Any pull requests are welcome and appreciated.

epoctic commented 3 months ago

I have a branch where I've implemented this feature, but I'm not really sure how to move forward with creating a reasonable integration test for it.

epoctic commented 3 months ago

@pahud Sorry about the long wait, but I was finally able to get a PR up! #30997