Search code examples
amazon-web-servicesaws-cloudformationaws-devops

Update some settings of an existing resource using Cloud Formation


I'm new to Cloud Formation. I want to update the settings of already created a lot of RDS instances using Cloud Formation. I don't have the info about either those resources were created through CF or manually. Is it possible to update such resources with CF? I can think of another way like I can use AWS SDK (boto3) but doing it with CF is perefrable.


Solution

  • The only way to do this from CloudFormation (CF) is to develop your own CF custom resource. This will be a lambda function which will use AWS SDK to query the state of your RDS databases, and perform any actions you want.

    Since its fully custom, you can program any logic which satisfies your requirements.

    If the resources were created manually, you can also import them to CF, and then update using CF.