Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

install: Support --nodes-without-cilium in Helm install mode #1498

Merged
merged 2 commits into from
Apr 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion defaults/defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,6 @@ var (
CiliumScheduleAffinity = map[string]string{
"affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].key": CiliumNoScheduleLabel,
"affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].operator": "NotIn",
"affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].values[0]": "true",
"affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[0].matchExpressions[0].values[0]": "'true'",
}
)
3 changes: 1 addition & 2 deletions internal/cli/cmd/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,6 @@ cilium install --context kind-cluster1 --cluster-id 1 --cluster-name cluster1
cmd.Flags().StringSliceVar(&params.APIVersions, "api-versions", []string{}, "Kubernetes API versions to use for helm's Capabilities.APIVersions in case discovery fails")
cmd.Flags().StringVar(&params.ImageSuffix, "image-suffix", "", "Set all generated images with this suffix")
cmd.Flags().StringVar(&params.ImageTag, "image-tag", "", "Set all images with this tag")
cmd.Flags().StringSliceVar(&params.NodesWithoutCilium, "nodes-without-cilium", []string{}, "List of node names on which Cilium will not be installed")

for flagName := range install.FlagsToHelmOpts {
// TODO(aanm) Do not mark the flags has deprecated for now.
Expand Down Expand Up @@ -236,7 +235,7 @@ func addCommonInstallFlags(cmd *cobra.Command, params *install.Parameters) {
cmd.Flags().BoolVar(&params.ListVersions, "list-versions", false, "List all the available versions without actually installing")
cmd.Flags().BoolVar(&params.Wait, "wait", false, "Wait for helm install to finish")
cmd.Flags().DurationVar(&params.WaitDuration, "wait-duration", defaults.StatusWaitDuration, "Maximum time to wait for status")

cmd.Flags().StringSliceVar(&params.NodesWithoutCilium, "nodes-without-cilium", []string{}, "List of node names on which Cilium will not be installed. In Helm installation mode, it's assumed that the no-schedule node labels are present.")
}

// addCommonUninstallFlags adds uninstall command flags that are shared between classic and helm mode.
Expand Down