Skip to content
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

[WIP] Add support for Task Roles when running on ECS or CodeBuild #14199

Closed
wants to merge 1 commit into from

Conversation

jekh
Copy link

@jekh jekh commented May 4, 2017

This PR is intended to address #8746. It adds the RemoteCredProvider from the AWS SDK if the AWS_CONTAINER_CREDENTIALS_RELATIVE_URI environment variable is set. The RemoteCredProvider uses the value of that environment variable and appends it to the hard-coded URL http://169.254.170.2, and uses the resulting URL to obtain Task Role credentials.

A few questions about the PR:

  1. I'm not sure what Handlers to provide to the RemoteCredProvider, so I went with the SDK defaults. Is this the right pattern to follow for adding this provider?
  2. Testing - This is quite difficult to unit test, as the SDK is hard-coded to use 169.254.170.2 for container credentials, making it difficult to mock. Any suggestions?
  3. (Somewhat tangential) What's the rationale behind a custom provider chain, rather than allowing the AWS SDK to find credentials using its default search path (at least when credentials aren't specified directly in TF)?

@blaines
Copy link

blaines commented Jun 9, 2017

Item 3 is a good point because I expect Terraform to behave similarly to a current aws-sdk

@jekh
Copy link
Author

jekh commented Aug 15, 2017

I'm going to close this PR as I've opened a PR against the AWS provider itself, #1425.

@jekh jekh closed this Aug 15, 2017
@jekh jekh deleted the support-ecs-task-roles branch October 16, 2017 05:08
@ghost
Copy link

ghost commented Apr 7, 2020

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.

@ghost ghost locked and limited conversation to collaborators Apr 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants