Upgrade to Electron 14.2.4 (#4625)

Co-authored-by: Sebastian Malton <sebastian@malton.name>
Co-authored-by: Jim Ehrismann <jehrismann@mirantis.com>
This commit is contained in:
authored and GitHub committed 2022-01-27 10:23:36 -05:00
1 parent 205225f6a4
commit 1cac3ca74c
58 files changed
+545 -418

No files matched your search

+5 -6
View File
@@ -9,11 +9,10 @@ import { ResourceApplier } from "../../main/resource-applier";
import type { KubernetesCluster } from "../catalog-entities";
import logger from "../../main/logger";
import { app } from "electron";
import { requestMain } from "../ipc";
import { clusterKubectlApplyAllHandler, clusterKubectlDeleteAllHandler } from "../cluster-ipc";
import { ClusterStore } from "../cluster-store/cluster-store";
import yaml from "js-yaml";
import { productName } from "../vars";
import { requestKubectlApplyAll, requestKubectlDeleteAll } from "../../renderer/ipc";
export class ResourceStack {
constructor(protected cluster: KubernetesCluster, protected name: string) {}
@@ -41,7 +40,7 @@ export class ResourceStack {
}
protected async applyResources(resources: string[], extraArgs?: string[]): Promise<string> {
const clusterModel = ClusterStore.getInstance().getById(this.cluster.metadata.uid);
const clusterModel = ClusterStore.getInstance().getById(this.cluster.getId());
if (!clusterModel) {
throw new Error(`cluster not found`);
@@ -54,7 +53,7 @@ export class ResourceStack {
if (app) {
return await new ResourceApplier(clusterModel).kubectlApplyAll(resources, kubectlArgs);
} else {
const response = await requestMain(clusterKubectlApplyAllHandler, this.cluster.metadata.uid, resources, kubectlArgs);
const response = await requestKubectlApplyAll(this.cluster.getId(), resources, kubectlArgs);
if (response.stderr) {
throw new Error(response.stderr);
@@ -65,7 +64,7 @@ export class ResourceStack {
}
protected async deleteResources(resources: string[], extraArgs?: string[]): Promise<string> {
const clusterModel = ClusterStore.getInstance().getById(this.cluster.metadata.uid);
const clusterModel = ClusterStore.getInstance().getById(this.cluster.getId());
if (!clusterModel) {
throw new Error(`cluster not found`);
@@ -78,7 +77,7 @@ export class ResourceStack {
if (app) {
return await new ResourceApplier(clusterModel).kubectlDeleteAll(resources, kubectlArgs);
} else {
const response = await requestMain(clusterKubectlDeleteAllHandler, this.cluster.metadata.uid, resources, kubectlArgs);
const response = await requestKubectlDeleteAll(this.cluster.getId(), resources, kubectlArgs);
if (response.stderr) {
throw new Error(response.stderr);