Skip to content

CloudFormation IaC generator cannot find any Cognito resources

0

I am wondering why the IaC generator scan cannot find any Cognito resources.

I have a couple of Cognito resources, what is the best way of importing them into CloudFormation?

2 Answers
0
Accepted Answer

Hello.

As stated in the documentation below, the IaC generator supports few Cognito resources as of February 2025.
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/resource-import-supported-resources.html
a

Therefore, the only option is to import Cognito resources into CloudFormation as described in the document below.
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/resource-import-existing-stack.html

EXPERT

answered 2 years ago

EXPERT

reviewed 2 years ago

0

There are a few potential reasons why the CloudFormation Infrastructure as Code (IaC) generator scan may not be finding any Cognito resources:

  1. Limited support: The IaC generator has limited support for Cognito resources. According to the resource type support information, only a few Cognito resource types are supported by the IaC generator. Specifically, only AWS::Cognito::IdentityPoolPrincipalTag is listed as supported for IaC generation. Other common Cognito resources like UserPools, IdentityPools, and UserPoolClients are not supported by the IaC generator.

  2. Regional availability: The IaC generator only supports resources that are also supported by the Cloud Control API in your specific AWS region. It's possible that Cognito resources may not be supported by Cloud Control API in the region you're scanning, which would prevent the IaC generator from detecting them.

  3. Resource configuration: If your Cognito resources were not originally created or managed through CloudFormation, they might not be detectable by the IaC generator scan.

To work around this limitation, you may need to manually create CloudFormation templates for your Cognito resources or use alternative IaC tools that have better support for Cognito resources. Additionally, you could check if your Cognito resources are supported by Cloud Control API in your region, as this is a prerequisite for IaC generator support.
Sources
Resource type support - AWS CloudFormation

answered 2 years ago

EXPERT

reviewed 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.