Skip to content

Commit

Permalink
fix: talosctl cluster create not to enforce kubeprism always
Browse files Browse the repository at this point in the history
The command should be able to deploy old versions of Talos as well,
even before KubePrism.

The version contract correctly enables/disables KubePrism by default, so
take default flag value as "don't change defaults".

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
  • Loading branch information
smira committed Dec 7, 2023
1 parent 320064c commit e128d3c
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions cmd/talosctl/cmd/mgmt/cluster/create.go
Expand Up @@ -523,9 +523,11 @@ func create(ctx context.Context, flags *pflag.FlagSet) (err error) {
)
}

genOptions = append(genOptions,
generate.WithKubePrismPort(kubePrismPort),
)
if kubePrismPort != constants.DefaultKubePrismPort {
genOptions = append(genOptions,
generate.WithKubePrismPort(kubePrismPort),
)
}

defaultInternalLB, defaultEndpoint := provisioner.GetLoadBalancers(request.Network)

Expand Down

0 comments on commit e128d3c

Please sign in to comment.