mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Extend ClusterManager from Singleton
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>
This commit is contained in:
parent
532b10e357
commit
d4c51e9986
@ -6,9 +6,11 @@ import { clusterStore, getClusterIdFromHost } from "../common/cluster-store"
|
|||||||
import { Cluster } from "./cluster"
|
import { Cluster } from "./cluster"
|
||||||
import logger from "./logger";
|
import logger from "./logger";
|
||||||
import { apiKubePrefix } from "../common/vars";
|
import { apiKubePrefix } from "../common/vars";
|
||||||
|
import { Singleton } from "../common/utils";
|
||||||
|
|
||||||
export class ClusterManager {
|
export class ClusterManager extends Singleton {
|
||||||
constructor(public readonly port: number) {
|
constructor(public readonly port: number) {
|
||||||
|
super()
|
||||||
// auto-init clusters
|
// auto-init clusters
|
||||||
autorun(() => {
|
autorun(() => {
|
||||||
clusterStore.enabledClustersList.forEach(cluster => {
|
clusterStore.enabledClustersList.forEach(cluster => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user