From 46c858bcbe3bc886d04895762deccf8dbce1c9bd Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Thu, 18 Aug 2016 11:27:17 -0400 Subject: [PATCH] provider/aws: Increase timeout for creating IAM role (#7733) --- builtin/providers/aws/resource_aws_iam_role.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/builtin/providers/aws/resource_aws_iam_role.go b/builtin/providers/aws/resource_aws_iam_role.go index 43d292b0d5df..7e56e79d8550 100644 --- a/builtin/providers/aws/resource_aws_iam_role.go +++ b/builtin/providers/aws/resource_aws_iam_role.go @@ -105,10 +105,10 @@ func resourceAwsIamRoleCreate(d *schema.ResourceData, meta interface{}) error { } var createResp *iam.CreateRoleOutput - err := resource.Retry(10*time.Second, func() *resource.RetryError { + err := resource.Retry(30*time.Second, func() *resource.RetryError { var err error createResp, err = iamconn.CreateRole(request) - // IAM roles can take ~10 seconds to propagate in AWS: + // IAM roles can take ~30 seconds to propagate in AWS: // http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console if isAWSErr(err, "MalformedPolicyDocument", "Invalid principal in policy") { return resource.RetryableError(err)