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

EKS Node Group Resource Tag Inheritance #13643

Closed
jornj-lululemon opened this issue Jun 5, 2020 · 6 comments · Fixed by #20674
Closed

EKS Node Group Resource Tag Inheritance #13643

jornj-lululemon opened this issue Jun 5, 2020 · 6 comments · Fixed by #20674
Labels
enhancement Requests to existing resources that expand the functionality or scope. service/autoscaling Issues and PRs that pertain to the autoscaling service.
Milestone

Comments

@jornj-lululemon
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • 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
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

Currently EKS Node Group resources create autoscaling groups that do not inherit or pass down any configuration defined tags except the default EKS service association tags. AWS EKS clusters (both on the cluster itself and created node groups) currently do not support tag propagation, and terraform only appears to track the autoscaling group name(s) created by the EKS node group resource. Since the AWS terraform provisioner does not have functionality to define supplemental tags on untracked resources, the current workaround seems to be creating a local_exec provisioner calling the AWS autoscaling CreateOrUpdateTags API call.

New or Affected Resource(s)

eks_node_group

Potential Terraform Configuration

autoscaling_group_tags = {
    "my.eksnodegroup.asg.key" = "value"
}

or

propagate_tags = true/false

References

https://docs.aws.amazon.com/eks/latest/userguide/eks-using-tags.html
https://docs.aws.amazon.com/autoscaling/ec2/APIReference/API_CreateOrUpdateTags.html

@jornj-lululemon jornj-lululemon added the enhancement Requests to existing resources that expand the functionality or scope. label Jun 5, 2020
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Jun 5, 2020
@ewbankkit
Copy link
Contributor

@jornj-lululemon Thanks for raising this issue.
As similar thought has been noted in #9061.
Let's keep this issue open until that is addressed.

@ewbankkit ewbankkit added service/eks Issues and PRs that pertain to the eks service. and removed needs-triage Waiting for first response or review from a maintainer. labels Jun 5, 2020
@jornj-lululemon
Copy link
Author

@ewbankkit Thanks for the triage, one thing to note is that the eks_node_group resources expose the autoscaling group name attribute list under aws_eks_node_group.my_resource_name.resources[*].autoscaling_groups[*].name so all the information necessary to passdown tags is available.

@DrFaust92
Copy link
Collaborator

FYI, Ive asked AWS SA that i work with to ask the EKS service team to address this, its seems to be in their roadmap.

@bflad bflad added service/autoscaling Issues and PRs that pertain to the autoscaling service. service/eks Issues and PRs that pertain to the eks service. upstream Addresses functionality related to the cloud provider. and removed service/eks Issues and PRs that pertain to the eks service. labels Jun 13, 2020
@bflad
Copy link
Contributor

bflad commented Jun 13, 2020

Please note I'm dual labeling this issue -- if the upstream EKS API implements tag propagation support, great! Otherwise, we can consider the following new resource type for managing Autoscaling tags in the meantime:

resource "aws_autoscaling_tag" "example" {
  key                 = "key1"
  propagate_at_launch = true
  resource_id         = aws_eks_node_group.my_resource_name.resources[*].autoscaling_groups[*].name
  value               = "value1"
}

@github-actions
Copy link

This functionality has been released in v3.56.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Requests to existing resources that expand the functionality or scope. service/autoscaling Issues and PRs that pertain to the autoscaling service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants