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

read tags through metadata not iam-rights (describetags) #1410

Open
dayByte opened this issue Nov 4, 2024 · 0 comments
Open

read tags through metadata not iam-rights (describetags) #1410

dayByte opened this issue Nov 4, 2024 · 0 comments

Comments

@dayByte
Copy link

dayByte commented Nov 4, 2024

If using auto scaling dimensions the IAM right describetags is needed. It would be better to read tags with the help of metadata when enabled.

TOKEN=$(curl -X PUT "http://169.254.169.254/latest/api/token" -H "X-aws-ec2-metadata-token-ttl-seconds:21600" 2>/dev/null)
$(curl -H "X-aws-ec2-metadata-token:$TOKEN" -s http://169.254.169.254/latest/meta-data/tags/instance/Name)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant