title: Pgp key in terraform for aws_iam_user_login_profile
body: <p>I am new to terraform creating iam user using terraform </p>
  
  <p>below is the .tf file </p>
  
  <pre><code>resource "aws_iam_user" "lb" {
    name = "Ec2_view"
  
    # path = "/system/"
    # tags = {
    #   tag-key = "tag-value"
    # }
  }
  
  resource "aws_iam_access_key" "lb" {
    user = "${aws_iam_user.lb.name}"
  }
  
  resource "aws_iam_user_policy" "lb_ro" {
    name = "test"
    user = "${aws_iam_user.lb.name}"
  
    policy = &lt;&lt;EOF
  {
    "Version": "2012-10-17",
    "Statement": [
      {
        "Action": [
          "ec2:Describe*"
        ],
        "Effect": "Allow",
        "Resource": "*"
      }
    ]
  }
  EOF
  }
  
  resource "aws_iam_user_login_profile" "u" {
    user                    = "${aws_iam_user.lb.name}"
    password_reset_required = true
    pgp_key="keybase:terraform_user"
  }
  
  output "password" {
  value="${aws_iam_user_login_profile.u.encrypted_password"
  }
  </code></pre>
  
  <p>what does pgp_key mean in aws_iam_user_login_profile and steps to create pgp_key and using it in terraform code?</p>