1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

remove auto-select clusters, clean up

Signed-off-by: Roman <ixrock@gmail.com>
This commit is contained in:
Roman 2020-08-27 16:37:01 +03:00
parent 4b5a4d8d1d
commit 55bb573421
2 changed files with 2 additions and 9 deletions

View File

@ -1,6 +1,5 @@
import { app, remote } from "electron";
import { KubeConfig, V1Node, V1Pod } from "@kubernetes/client-node"
import fse, { ensureDirSync, writeFileSync } from "fs-extra";
import fse from "fs-extra";
import path from "path"
import os from "os"
import yaml from "js-yaml"

View File

@ -71,7 +71,7 @@ export class AddCluster extends React.Component {
}
@action
refreshContexts(autoSelect = true) {
refreshContexts() {
this.selectedContexts.clear();
this.kubeContexts.clear();
@ -91,12 +91,6 @@ export class AddCluster extends React.Component {
}
break;
}
if (autoSelect) {
const allContexts = Array.from(this.kubeContexts.keys());
if (allContexts.length <= 10) {
this.selectedContexts.replace(allContexts);
}
}
}
getContexts(config: KubeConfig): Map<string, KubeConfig> {