-
Notifications
You must be signed in to change notification settings - Fork 9.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Terraform does not use IAM Role for ECS Task as credential provider #259
Comments
@stack72 This is still an issue on 0.9.10. Any hope of fixing this in the near future? terraform should try getting the ECS credentials before the instance-profile credentials. |
I hope Terraform will be able to get these credentials for use in CodeBuild. For now I am doing the following:
Cheers! |
This was implemented in #1425 which was just merged. |
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
workaround terraform not using ECS task role for S3 backend hashicorp/terraform-provider-aws#259 hashicorp/terraform-provider-terraform#15
Here's a similar workaround to the one above for CodeBuild which may be useful in a python container with minimal bash utilities. Placed in the buildspec file.
|
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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
This issue was originally opened by @iwat as hashicorp/terraform#8746. It was migrated here as part of the provider split. The original body of the issue is below.
Terraform Version
Terraform v0.7.3
Affected Resource(s)
This affects all AWS related command.
Terraform Configuration Files
Debug Output
https://gist.github.com/iwat/df0b0ebfe2f8db62adfd5953bfd6b92c
Panic Output
None
Expected Behavior
It should work by using IAM Role for ECS Task.
awscli works
Actual Behavior
It was using EC2 Instance Role which does not allow this action.
Error retrieving Target Group: AccessDenied: User: arn:aws:sts::872767853649:assumed-role/myrole/i-0223aeb98c19f2d0d
Steps to Reproduce
Important Factoids
None
References
The text was updated successfully, but these errors were encountered: