-
Notifications
You must be signed in to change notification settings - Fork 9.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AutoVerifiedAttributes for CognitoUserPool being removed by terraform #3009
Comments
Tried to see what happened here but found myself lack of understanding terraform.
From debug log, there is no |
seems like when |
@louy By saying |
I believe so |
So after further testing, I can confirm the following With email verification turned on in the console:
Then if I turn it off using the console:
Looking at the code here, it looks like terraform expects an empty array in the second case but AWS returns |
The fix for this has been merged into master and will be released with v1.12.0 of the AWS provider, likely in about a week. |
This has been released in version 1.12.0 of the AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. |
I'm using v1.26.0 of the AWS provider, My configuration: resource "aws_cognito_user_pool" "cognito_user_pool" {
name = cognito_user_pool-${var.namespace}"
verification_message_template {
default_email_option = "CONFIRM_WITH_CODE"
email_message = "Your verification code is {####}."
email_subject = "Your verification code"
}
password_policy {
minimum_length = 8
require_numbers = true
require_symbols = true
require_lowercase = true
require_uppercase = true
}
admin_create_user_config {
allow_admin_create_user_only = true
unused_account_validity_days = 7
invite_message_template {
email_message = "Your login information is {username} and your password is {####}."
email_subject = "Welcome!"
sms_message = "WelcomeL! Your login information is {username} and your password is {####}."
}
}
auto_verified_attributes = ["email"]
schema {
attribute_data_type = "String"
developer_only_attribute = false
mutable = false
name = "email"
required = false
string_attribute_constraints {
min_length = 7
max_length = 30
}
}
} Every run of
|
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Hi,
I'm having a strange behaviour with
aws_cognito_user_pool
. Sorry if this doesn't contain enough information. I can provide a bit more if needed.Terraform Version
Affected Resource
aws_cognito_user_pool
Terraform Configuration Files
Expected Behavior
AutoVerifiedAttributes
should containemail
Actual Behavior
AutoVerifiedAttributes
doesn't containemail
Steps to Reproduce
aws cognito-idp describe-user-pool --user-pool-id eu-west-2_XXXXXX > output1.txt
terraform apply
aws cognito-idp describe-user-pool --user-pool-id eu-west-2_XXXXXX > output2.txt
diff output1.txt output2.txt
You can see that for some reason
AutoVerifiedAttributes
is gone fromoutput2.txt
The text was updated successfully, but these errors were encountered: