-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Labels
@aws-cdk/aws-rdsRelated to Amazon Relational DatabaseRelated to Amazon Relational DatabasebugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortin-progressThis issue is being actively worked on.This issue is being actively worked on.p1
Description
What is the problem?
Any way to import an existing DB secret and use it with an RDS ServerlessCluster?
If I use secretsmanager.Secret.fromSecretNameV2() it returns an ISecret but SnapshotCredentials.fromSecret(secret) wants a Secret
Seems like I can't import a secret and use it as credentials for a DB created from snapshot.
I did this:
const dbSecret = SnapshotCredentials.fromGeneratedSecret("postgres");
db = new DatabaseFromSnapshot(this, "DB", {
...dbProps,
engine: DatabaseClusterEngine.AURORA_POSTGRESQL,
snapshotIdentifier: dbSnapshotName,
credentials: dbSecret,
});And it seems like it generates a new password for me at random times when I deploy. Not really what I want at all.
Reproduction Steps
See above code
What did you expect to happen?
Be able to use an existing secret with a DB from snapshot.
What actually happened?
CDK CLI Version
2.7.0
Framework Version
2.7.0
Node.js Version
14
OS
MacOS
Language
Typescript
Language Version
4.6
Other information
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
@aws-cdk/aws-rdsRelated to Amazon Relational DatabaseRelated to Amazon Relational DatabasebugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortin-progressThis issue is being actively worked on.This issue is being actively worked on.p1
