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

IAM instance roles not available for cloud-init #7999

Closed
trajano opened this issue Mar 18, 2019 · 2 comments
Closed

IAM instance roles not available for cloud-init #7999

trajano opened this issue Mar 18, 2019 · 2 comments
Labels
service/ec2 Issues and PRs that pertain to the ec2 service. service/iam Issues and PRs that pertain to the iam service.

Comments

@trajano
Copy link

trajano commented Mar 18, 2019

Terraform Version

$ terraform -v
Terraform v0.11.11

  • provider.aws v2.1.0 (or 2.2.0)
  • provider.template v1.0.0
  • provider.tls v1.2.0

Affected Resource(s)

  • aws_instance
  • aws_iam_role

Terraform Configuration Files

https://registry.terraform.io/modules/trajano/swarm-aws/docker/2.3.2

Just changed from AWS 2.1 to AWS 2.2 in the samples and the instance credentials do not appear to be present during cloud init but works when you run the same script inside and curling the meta data shows the instance ID. So it appears to be a timing issue because it works with a t3.micro but not a t3.small which is a slightly faster machine.

# Copy-paste your Terraform configurations here - for large Terraform configs,
# please use a service like Dropbox and share a link to the ZIP file. For
# security, you can also encrypt the files using our GPG public key: https://keybase.io/hashicorp

Debug Output

Panic Output

Expected Behavior

Everything should be provisioned correctly.

Actual Behavior

I get an error saying missing credentials when invoking boto3 in cloud-init

Steps to Reproduce

  1. terraform apply

Important Factoids

References

  • #0000
@aeschright aeschright added the needs-triage Waiting for first response or review from a maintainer. label Jun 19, 2019
@aeschright aeschright added service/ec2 Issues and PRs that pertain to the ec2 service. service/iam Issues and PRs that pertain to the iam service. labels Jul 2, 2019
@aeschright
Copy link
Contributor

Hi @trajano 👋 We need the specific relevant parts of your config in the bug report and the full debug output to follow up on this. If you're still encountering a problem, please open a new issue with that information. Thanks!

@aeschright aeschright removed the needs-triage Waiting for first response or review from a maintainer. label Dec 9, 2019
@ghost
Copy link

ghost commented Mar 28, 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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
service/ec2 Issues and PRs that pertain to the ec2 service. service/iam Issues and PRs that pertain to the iam service.
Projects
None yet
Development

No branches or pull requests

2 participants