Ismael Correa
Ismael Correa

Reputation: 9

Associate role to RDS instance that already exists using CDK

i'm new to using the CDK. I want to do exactly the same thing described in this discussion, however i don't want to create the RDS instance as it already exists. How can i add the IAM Role to an already existing RDS instance?

Upvotes: 0

Views: 586

Answers (1)

Matthew Bonig
Matthew Bonig

Reputation: 2136

If the RDS instance already exists, and is not controlled through CloudFormation and/or the CDK, then you have two options:

  1. Import the RDS instance into a CloudFormation stack, letting the stack take ownership of the RDS and manage it going forward. You can find additional information here.
  2. Use a Custom Resource to make an API call to add the IAM role.

Upvotes: 2

Related Questions