terraform-aws-modules / terraform-aws-ec2-instance

Terraform module to create AWS EC2 instance(s) resources πŸ‡ΊπŸ‡¦
https://registry.terraform.io/modules/terraform-aws-modules/ec2-instance/aws
Apache License 2.0
758 stars 1.88k forks source link

Attach an instance profile to the EC2 instance #309

Closed mgarrett2008 closed 1 year ago

mgarrett2008 commented 1 year ago

Is your request related to a new offering from AWS?

Is this functionality available in the AWS provider for Terraform? See CHANGELOG.md, too.

Is your request related to a problem? Please describe.

I am looking to use IAM roles to grant permissions to applications running on Amazon EC2 instances. An IAM instance profile is the entity that allows IAM role attachment with an EC2 instance. Because role credentials are temporary and rotated automatically, you don't have to manage credentials, and you don't have to worry about long-term security risks.

Describe the solution you'd like.

I would like to include the optional input parameter iam_instance_profile passed through to the EC2 instance resource so when launched, the IAM role will be attached.

Describe alternatives you've considered.

Additional context

github-actions[bot] commented 1 year ago

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.