createClusterTask creates the cluster
(ctx context.Context, errs chan error, supportsManagedNodes bool)
| 34 | |
| 35 | // createClusterTask creates the cluster |
| 36 | func (c *StackCollection) createClusterTask(ctx context.Context, errs chan error, supportsManagedNodes bool) error { |
| 37 | name := c.MakeClusterStackName() |
| 38 | logger.Info("building cluster stack %q", name) |
| 39 | |
| 40 | stack := builder.NewClusterResourceSet(c.ec2API, c.stsAPI, c.region, c.spec, nil, false) |
| 41 | if err := stack.AddAllResources(ctx); err != nil { |
| 42 | return err |
| 43 | } |
| 44 | |
| 45 | return c.createClusterStack(ctx, name, stack, errs) |
| 46 | } |
| 47 | |
| 48 | // DescribeClusterStackIfExists calls ListStacks and filters out cluster stack. |
| 49 | // If the stack does not exist, it returns nil. |
no test coverage detected