aws-cloudformation / rain

A development workflow tool for working with AWS CloudFormation.
Apache License 2.0
749 stars 69 forks source link

Support Resource Import for Manually Created Infrastructure #396

Open ggiallo28 opened 1 month ago

ggiallo28 commented 1 month ago

Description:

Rain build is very nice, and using generative AI to create a starting template is cool. But what if Rain also supported resource import?

For example, you could provide the resource ID, and it would generate the CloudFormation template for that resource. You could use AWS CLI to describe or get a specific resource you created, and the generative AI would transform this returned configuration into a CloudFormation template.

Ok, maybe GenAI is not needed in that case, but having this feature would be a game changer. It could work like Terraform import.

There is already the CloudFormation IaC generator, but it takes time to scan all the resources in the account. Having the possibility to target a specific resource would be better. Additionally, the IaC generator does not support all resources. Bedrock can do a great job for currently unsupported resources by transforming JSON responses into YAML resources.

ericzbeard commented 1 month ago

Interesting idea! The big thing that IaC generator is doing for you is converting the resources into a managed stack without any extra steps. Maybe we could find an intuitive way for Rain to make the process easier.