Create IAM users by Terraform

Good day, all. My name is Lucas, and I hope you are doing great.

Please, I am trying to configure a Terraform plan to create new AWS IAM users automatically by Terraform. About users, I’m right for now.
My question is, please, how can I declare (attach) some policy that “already exists” to this user when it is created?


  • Create a user with name: lterr-test
    – I have a policy that call DevOps-Aut-Admin
    — Create the user “lterr-test” attached with the policy “DevOps-Aut-Admin”.

Thank you very much in advance for your attention, folks.