Skip to content
This repository has been archived by the owner on Jun 28, 2023. It is now read-only.

Remove reference to standalone cluster #2910

Closed
wants to merge 1 commit into from
Closed
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
8 changes: 0 additions & 8 deletions cli/cmd/plugin/diagnostics/pkg/collect_cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ var (
}

workloadArgs = collectWorkloadArgs{
standalone: false,
infra: "docker",
}
)
Expand All @@ -56,7 +55,6 @@ func CollectCmd(fs embed.FS) *cobra.Command {
mgmtArgs.clusterName = mgmtSvr.name
mgmtArgs.contextName = mgmtSvr.kubecontext
} else {
workloadArgs.standalone = true
workloadArgs.kubeconfig = getDefaultKubeconfig()
}

Expand All @@ -81,7 +79,6 @@ func CollectCmd(fs embed.FS) *cobra.Command {
cmd.Flags().StringVar(&mgmtArgs.contextName, "management-cluster-context", mgmtArgs.contextName, "The context name of the management cluster (required)")

// workload
cmd.Flags().BoolVar(&workloadArgs.standalone, "workload-cluster-standalone", workloadArgs.standalone, "If true, workload cluster is treated as standalone")
cmd.Flags().StringVar(&workloadArgs.infra, "workload-cluster-infra", workloadArgs.infra, "Overrides the infrastructure type for the managed cluster (i.e. aws, azure, vsphere, etc)")
cmd.Flags().StringVar(&workloadArgs.clusterName, "workload-cluster-name", workloadArgs.clusterName, "The name of the managed cluster for which to collect diagnostics (required)")
cmd.Flags().StringVar(&workloadArgs.namespace, "workload-cluster-namespace", workloadArgs.namespace, "The namespace where managed workload resources are stored (required)")
Expand Down Expand Up @@ -264,11 +261,6 @@ func collectWorkloadDiags() error {
}

scriptName := wcScriptPath
if workloadArgs.standalone {
argsMap["workload_kubeconfig"] = getDefaultKubeconfig()
argsMap["workload_context"] = getDefaultClusterContext(workloadArgs.clusterName)
}

libScript := libScriptPath
libData, err := scriptFS.ReadFile(libScript)
if err != nil {
Expand Down