Skip to content

Commit ff8d8da

Browse files
SlavaKatiukhadfateyev
authored andcommitted
K8S-529
K8S-529 [K8s]: Cluster upgrade fails from 1.18.10 to 1.20.6
1 parent f68e7fe commit ff8d8da

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

addons/upgrade.jps

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ actions:
247247
resp = resp.response || resp;
248248
if (resp.result != 0) return resp;
249249

250-
var apps = resp.apps, newAddons = {}, mainApp = {}, newJps;
250+
var apps = resp.apps, newAddons = {}, mainApp = {}, newJps, nodeGroup;
251251

252252
try {
253253
newJps = toNative(new org.yaml.snakeyaml.Yaml().load(new com.hivext.api.core.utils.Transport().get(manifestUrl)));
@@ -266,7 +266,7 @@ actions:
266266
var batch = { alias : { m : "Development.Scripting.Eval" }, global : { appid: "appstore", session: session }, methods: [] };
267267

268268
for (var i = 0, n = apps.length; i < n; i++) {
269-
var app = apps[i], nodeGroup = "", jps;
269+
var app = apps[i], jps;
270270

271271
if (!app.isInstalled) continue;
272272
app.settings.data = app.settings.data || {};
@@ -292,6 +292,7 @@ actions:
292292

293293
if (mainApp) {
294294
mainApp = mainApp["kubernetes-release"] || mainApp.kubernetes;
295+
nodeGroup = "";
295296
schedule(mainApp.jps, batch, mainApp.data);
296297
} else return { result: com.hivext.api.Response.OBJECT_FORMAT_ERROR, error: "Kubernetes manifest is not found!", data: ex};
297298

0 commit comments

Comments
 (0)