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 <[email protected]>
(cherry picked from commit e128d3c)
  • Loading branch information
smira committed Dec 8, 2023
1 parent 41fc054 commit fe66611
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .conform.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ policies:
gitHubOrganization: siderolabs
spellcheck:
locale: US
maximumOfOneCommit: true
maximumOfOneCommit: false
header:
length: 89
imperative: true
Expand Down
8 changes: 5 additions & 3 deletions cmd/talosctl/cmd/mgmt/cluster/create.go
Original file line number Diff line number Diff line change
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 fe66611

Please sign in to comment.