pulumi-eks icon indicating copy to clipboard operation
pulumi-eks copied to clipboard

[Go] Managed Node Groups missing inputs for certain configuration options in Go SDK

Open zeevallin opened this issue 3 years ago • 2 comments

Hello!

  • Vote on this issue by adding a 👍 reaction
  • If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

When working with the Go implementation, a few fields does not have any corresponding configuration structs when working with Managed Node Groups. They exist on the node group args, but they are not available from the eks package. It would be nice if these configuration options were also implemented for Go.

ng, err := eks.NewManagedNodeGroup(ctx, "node-group", &eks.ManagedNodeGroupArgs{
	// Fields not implemented
	LaunchTemplate: nil,
	RemoteAccess:   nil,
	ScalingConfig:  nil,
})

Affected area/feature

  • Go SDK

zeevallin avatar Oct 14 '22 08:10 zeevallin

Have you considered nodegroupv2? Its just recently added and it has a few bugs we are tracking but that might give you the control you want. ManagedNodeGroup is more opinionated.

viveklak avatar Oct 15 '22 01:10 viveklak

Hey @viveklak, I have tried NodeGroupV2 and I had a lot of issues getting the nodes joining the cluster, not to mention they used launch configs rather than launch templates. Managed node groups works very well for me, but being able to set the launch template configuration would really alleviate a lot of things.

zeevallin avatar Oct 17 '22 08:10 zeevallin

This should be currently supported and useable. Note that the types are coming from the AWS provider (pulumi-aws), so you'll need additional imports in your code for this to work.

Example:

import awsEks "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/eks"
import "github.com/pulumi/pulumi-eks/sdk/v2/go/eks"

ng, err := eks.NewManagedNodeGroup(ctx, "node-group", &eks.ManagedNodeGroupArgs{
    LaunchTemplate: awsEks.NodeGroupLaunchTemplateArgs{Id: pulumi.String("lt-0a1b2c3d")},
    RemoteAccess:   awsEks.NodeGroupRemoteAccessArgs{},
    ScalingConfig:  awsEks.NodeGroupScalingConfigArgs{},
})

rquitales avatar Apr 22 '24 23:04 rquitales