kube2iam
kube2iam copied to clipboard
update doHealthcheck to support IMDSv2
What this PR does / why we need it:
IMDSv2 need token, IMDSv1 Also works with token so no need to special flags. but feel free to do another PR with more elegant code. I'm not a Go Programmer so some things might be done wrongly,
Which issue this PR fixes
(optional, in fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close that issue when PR gets merged)
- fixes #
Special notes:
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html
Checklist chart
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]