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

[Bug]: launch template default value changed: http_token #30382

Open
tburow opened this issue Mar 31, 2023 · 6 comments
Open

[Bug]: launch template default value changed: http_token #30382

tburow opened this issue Mar 31, 2023 · 6 comments
Assignees
Labels
bug Addresses a defect in current functionality. service/ec2 Issues and PRs that pertain to the ec2 service.

Comments

@tburow
Copy link

tburow commented Mar 31, 2023

Terraform Core Version

v1.4.2

AWS Provider Version

4.61.0

Affected Resource(s)

https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/launch_template#metadata-options

http_token default value from 4.60.0 to 4.61.0 changed from optional to required under change #30107

This is a breaking change not declared in the pull request, release notes or documentation

Expected Behavior

http_token default value should either remain as "optional" or this change needs to be fully documented in both the release and current documentation.

Actual Behavior

http_token = required

breaks ec2 instance metadata operations unless properly coordinated with supporting code and or resource changes

Relevant Error/Panic Output Snippet

No response

Terraform Configuration Files

n/a

Steps to Reproduce

n/a

Debug Output

n/a

Panic Output

n/a

Important Factoids

Code impact:
this impacts both java and python application code methods

Configuration impact:
Docker containers running on EC2, from a launch template will fail to retrieve role credentials due to IDMS version changes with out additional required config modification

References

#30107

https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/launch_template#metadata-options

Would you like to implement a fix?

None

@tburow tburow added bug Addresses a defect in current functionality. needs-triage Waiting for first response or review from a maintainer. labels Mar 31, 2023
@github-actions
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@github-actions github-actions bot removed the needs-triage Waiting for first response or review from a maintainer. label Mar 31, 2023
@ewbankkit ewbankkit added the service/ec2 Issues and PRs that pertain to the ec2 service. label Mar 31, 2023
@gdavison
Copy link
Contributor

gdavison commented Apr 6, 2023

Hi @tburow, can you please share your configuration? I'm trying to reproduce the problem, and I get "", which means that the Launch Template doesn't specify a value, in both v4.60.0 and v4.61.0. In the AWS Console, you can also check this as the value for "Metadata version" on the "Advanced details" tab for the Launch Template.

Do you have multiple versions of the Launch Template, or is this for a new Launch Template?

@gdavison gdavison self-assigned this Apr 6, 2023
@gdavison gdavison added the waiting-response Maintainers are waiting on response from community or contributor. label Apr 6, 2023
@tburow
Copy link
Author

tburow commented Apr 7, 2023

ok - so if the resource module is not specifying a default value then im not sure what to say. Give me till monday to chase down the developer and get the code.

@github-actions github-actions bot removed the waiting-response Maintainers are waiting on response from community or contributor. label Apr 7, 2023
@Indresh2410
Copy link
Contributor

@tburow
Copy link
Author

tburow commented Apr 10, 2023

yes essentially we did not have the meta block defined - then from .60 to .61 the default behavior changed. I was unable to find in code where it flipped - perhaps an CLI/SDK default change if there were other changes in the release code.

I was not able to confirm with AWS if they changed anything on their end. Our AWS support team is not aware of any EC2 releases over the same period.

At a min - maybe an update of the release notes and documentation to reflect the changed behavior.

@supergibbs
Copy link
Contributor

supergibbs commented Sep 11, 2023

This just confused me as well for aws_instance. Docs say http_tokens defaults to optional but in practice, it was required. It may be AWS API change but docs are misleading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Addresses a defect in current functionality. service/ec2 Issues and PRs that pertain to the ec2 service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants