mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
cluster-store-3.6.0 migration regression fix
Signed-off-by: Roman <ixrock@gmail.com>
This commit is contained in:
1 parent
a305b04292
commit
67377af52e
2 files changed
+7
-6
No files matched your search
@@ -6,6 +6,7 @@ import { migration } from "../migration-wrapper";
|
||||
import { ensureDirSync } from "fs-extra"
|
||||
import { writeEmbeddedKubeConfig } from "../../common/utils/kubeconfig"
|
||||
import { ClusterModel } from "../../common/cluster-store";
|
||||
import { loadConfig } from "../../main/k8s";
|
||||
|
||||
export default migration({
|
||||
version: "3.6.0-beta.1",
|
||||
@@ -22,6 +23,7 @@ export default migration({
|
||||
try {
|
||||
// take the embedded kubeconfig and dump it into a file
|
||||
cluster.kubeConfigPath = writeEmbeddedKubeConfig(cluster.id, cluster.kubeConfig)
|
||||
cluster.contextName = loadConfig(cluster.kubeConfigPath).getCurrentContext();
|
||||
delete cluster.kubeConfig;
|
||||
migratedClusters.push(cluster)
|
||||
} catch (error) {
|
||||
|
||||
Reference in new issue
Block a user