From eb1a58d966859f0135ef43661cf8f5397e578ade Mon Sep 17 00:00:00 2001 From: Masayuki Morita Date: Sun, 30 Oct 2016 00:20:18 +0900 Subject: [PATCH] Update doc: aws_iam_user with force_destroy deletes IAM User Login Profile (#9716) refs: https://github.com/hashicorp/terraform/pull/9583 --- builtin/providers/aws/resource_aws_iam_user.go | 4 ++-- website/source/docs/providers/aws/r/iam_user.html.markdown | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/builtin/providers/aws/resource_aws_iam_user.go b/builtin/providers/aws/resource_aws_iam_user.go index 40a866e8c..761d9d85a 100644 --- a/builtin/providers/aws/resource_aws_iam_user.go +++ b/builtin/providers/aws/resource_aws_iam_user.go @@ -54,7 +54,7 @@ func resourceAwsIamUser() *schema.Resource { Type: schema.TypeBool, Optional: true, Default: false, - Description: "Delete user even if it has non-Terraform-managed IAM access keys", + Description: "Delete user even if it has non-Terraform-managed IAM access keys and login profile", }, }, } @@ -167,7 +167,7 @@ func resourceAwsIamUserDelete(d *schema.ResourceData, meta interface{}) error { } } - // All access keys for the user must be removed + // All access keys and login profile for the user must be removed if d.Get("force_destroy").(bool) { var accessKeys []string listAccessKeys := &iam.ListAccessKeysInput{ diff --git a/website/source/docs/providers/aws/r/iam_user.html.markdown b/website/source/docs/providers/aws/r/iam_user.html.markdown index e1832d3ed..69d54e62e 100644 --- a/website/source/docs/providers/aws/r/iam_user.html.markdown +++ b/website/source/docs/providers/aws/r/iam_user.html.markdown @@ -49,8 +49,8 @@ The following arguments are supported: * `name` - (Required) The user's name. The name must consist of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: `=,.@-_.`. User names are not distinguished by case. For example, you cannot create users named both "TESTUSER" and "testuser". * `path` - (Optional, default "/") Path in which to create the user. * `force_destroy` - (Optional, default false) When destroying this user, destroy - even if it has non-Terraform-managed IAM access keys. Without `force_destroy` - a user with non-Terraform-managed access keys will fail to be destroyed. + even if it has non-Terraform-managed IAM access keys and login profile. Without `force_destroy` + a user with non-Terraform-managed access keys and login profile will fail to be destroyed. ## Attributes Reference