Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Bug]: terraform-provider-aws_v5.76.0_x5 plugin crashed for eks_addon #40165

Closed
asimerel opened this issue Nov 18, 2024 · 5 comments · Fixed by #40168
Closed

[Bug]: terraform-provider-aws_v5.76.0_x5 plugin crashed for eks_addon #40165

asimerel opened this issue Nov 18, 2024 · 5 comments · Fixed by #40168
Assignees
Labels
bug Addresses a defect in current functionality. crash Results from or addresses a Terraform crash or kernel panic. service/eks Issues and PRs that pertain to the eks service.
Milestone

Comments

@asimerel
Copy link

asimerel commented Nov 18, 2024

Terraform Core Version

v1.5.7

AWS Provider Version

v5.76.0

Affected Resource(s)

  • aws_eks_addon

Expected Behavior

Addon configuration would be changed from using irsa to pod identity

Actual Behavior

terraform apply command is not working because plugin crashes

Relevant Error/Panic Output Snippet

│ The plugin encountered an error, and failed to respond to the plugin.(*GRPCProvider).ApplyResourceChange call. The plugin logs may contain more details.
╵
Releasing state lock. This may take a few moments...

Stack trace from the terraform-provider-aws_v5.76.0_x5 plugin:

panic: interface conversion: interface {} is *schema.Set, not []interface {}

goroutine 353 [running]:
github.com/hashicorp/terraform-provider-aws/internal/service/eks.resourceAddonUpdate({0x1196189a8, 0x14001bbedb0}, 0x14006991c00, {0x1192eeb60, 0x140003aaa00})
        github.com/hashicorp/terraform-provider-aws/internal/service/eks/addon.go:289 +0xdac
github.com/hashicorp/terraform-provider-aws/internal/provider.New.(*wrappedResource).Update.interceptedHandler[...].func11(0x14006991c00?, {0x1192eeb60?, 0x140003aaa00})
        github.com/hashicorp/terraform-provider-aws/internal/provider/intercept.go:113 +0x1d8
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).update(0x1196189a8?, {0x1196189a8?, 0x140019e8ea0?}, 0xd?, {0x1192eeb60?, 0x140003aaa00?})
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.35.0/helper/schema/resource.go:835 +0x64
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0x14001899c00, {0x1196189a8, 0x140019e8ea0}, 0x140069c25b0, 0x14006991a80, {0x1192eeb60, 0x140003aaa00})
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.35.0/helper/schema/resource.go:947 +0x660
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0x14002d944b0, {0x1196189a8?, 0x140019e8ae0?}, 0x14004cf2050)
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.35.0/helper/schema/grpc_provider.go:1155 +0xaa4
github.com/hashicorp/terraform-plugin-mux/tf5muxserver.(*muxServer).ApplyResourceChange(0x14001323a00, {0x1196189a8?, 0x140019e3f20?}, 0x14004cf2050)
        github.com/hashicorp/terraform-plugin-mux@v0.17.0/tf5muxserver/mux_server_ApplyResourceChange.go:36 +0x184
github.com/hashicorp/terraform-plugin-go/tfprotov5/tf5server.(*server).ApplyResourceChange(0x140021172c0, {0x1196189a8?, 0x140019dd440?}, 0x140069cf7a0)
        github.com/hashicorp/terraform-plugin-go@v0.25.0/tfprotov5/tf5server/server.go:865 +0x2a8
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0x119186d80, 0x140021172c0}, {0x1196189a8, 0x140019dd440}, 0x14006991700, 0x0)
        github.com/hashicorp/terraform-plugin-go@v0.25.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:611 +0x1c0
google.golang.org/grpc.(*Server).processUnaryRPC(0x1400159d000, {0x1196189a8, 0x140019dd170}, {0x1196985c0, 0x14002fba000}, 0x14003f85440, 0x14002dd7d40, 0x1241083f8, 0x0)
        google.golang.org/grpc@v1.67.1/server.go:1394 +0xb64
google.golang.org/grpc.(*Server).handleStream(0x1400159d000, {0x1196985c0, 0x14002fba000}, 0x14003f85440)
        google.golang.org/grpc@v1.67.1/server.go:1805 +0xb20
google.golang.org/grpc.(*Server).serveStreams.func2.1()
        google.golang.org/grpc@v1.67.1/server.go:1029 +0x84
created by google.golang.org/grpc.(*Server).serveStreams.func2 in goroutine 52
        google.golang.org/grpc@v1.67.1/server.go:1040 +0x13c

Error: The terraform-provider-aws_v5.76.0_x5 plugin crashed!

Terraform Configuration Files

#before

resource "aws_eks_addon" "aws_ebs_csi_driver" {
  cluster_name                = "some_cluster"
  addon_name                  = "aws-ebs-csi-driver"
  resolve_conflicts_on_update = "OVERWRITE"
  service_account_role_arn    = "some_role_arn"
}

#after

resource "aws_eks_addon" "aws_ebs_csi_driver" {
  cluster_name                = "some_cluster"
  addon_name                  = "aws-ebs-csi-driver"
  resolve_conflicts_on_update = "OVERWRITE"
  pod_identity_association {
    role_arn        = "some_pod_identity_role_arn"
    service_account = "ebs-csi-controller-sa"
  }
}

Steps to Reproduce

Create aws eks addon with service_account_role_arn then change it to use pod identity with deleting service_account_role_arn and adding pod_identity_association.
The terraform apply after changing addon from using IRSA to Pod Identity crashes

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

No response

Would you like to implement a fix?

No

@asimerel asimerel added the bug Addresses a defect in current functionality. label Nov 18, 2024
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 added crash Results from or addresses a Terraform crash or kernel panic. service/eks Issues and PRs that pertain to the eks service. needs-triage Waiting for first response or review from a maintainer. labels Nov 18, 2024
@justinretzolk justinretzolk added crash Results from or addresses a Terraform crash or kernel panic. and removed crash Results from or addresses a Terraform crash or kernel panic. needs-triage Waiting for first response or review from a maintainer. labels Nov 18, 2024
@terraform-aws-provider terraform-aws-provider bot added the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Nov 18, 2024
@jar-b
Copy link
Member

jar-b commented Nov 18, 2024

Relates #39973

Copy link

Warning

This issue has been closed, meaning that any additional comments are hard for our team to see. Please assume that the maintainers will not see them.

Ongoing conversations amongst community members are welcome, however, the issue will be locked after 30 days. Moving conversations to another venue, such as the AWS Provider forum, is recommended. If you have additional concerns, please open a new issue, referencing this one where needed.

@github-actions github-actions bot added this to the v5.77.0 milestone Nov 19, 2024
@github-actions github-actions bot removed the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Nov 21, 2024
Copy link

This functionality has been released in v5.77.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!

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 Dec 23, 2024
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
bug Addresses a defect in current functionality. crash Results from or addresses a Terraform crash or kernel panic. service/eks Issues and PRs that pertain to the eks service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants