Skip to content

Commit 0a89fd9

Browse files
fixing Verrazzano 1.4+ installation issue (#182)
* fixing Verrazzano 1.4+ installation issue * fixing comment typo
1 parent 1f3b014 commit 0a89fd9

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

electron/app/js/vzInstaller.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,17 @@ async function installVerrazzanoPlatformOperator(kubectlExe, k8sOptions, vzOptio
4242
let platformOperatorUrl;
4343

4444
if (vzOptions.tag) {
45+
const version = vzOptions.tag.slice(1);
46+
if (compareVersions(version, '1.4.0') >= 0) {
47+
platformOperatorUrl = `${VZ_BASE_URL}/releases/download/${vzOptions.tag}/verrazzano-platform-operator.yaml`;
48+
} else {
49+
// Before Verrazzano 1.4, the operator file name was operator.yaml...
50+
//
51+
platformOperatorUrl = `${VZ_BASE_URL}/releases/download/${vzOptions.tag}/operator.yaml`;
52+
}
4553
platformOperatorUrl = `${VZ_BASE_URL}/releases/download/${vzOptions.tag}/operator.yaml`;
4654
} else {
47-
platformOperatorUrl = `${VZ_BASE_URL}/releases/latest/operator.yaml`;
55+
platformOperatorUrl = `${VZ_BASE_URL}/releases/latest/verrazzano-platform-operator.yaml`;
4856
}
4957

5058
return new Promise(resolve => {

webui/src/js/viewModels/vz-install-design-view.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,9 @@ function (project, accUtils, utils, ko, i18n, screenUtils, BufferingDataProvider
4141
this.vzVersions = ko.observableArray();
4242
this.vzVersionTags = new ArrayDataProvider(this.vzVersions, {keyAttributes: 'tag'});
4343
window.api.ipc.invoke('get-verrazzano-release-versions', MINIMUM_VERRAZZANO_VERSION).then(versions => {
44+
// Sort in descending order by version number.
45+
//
46+
versions.sort((a, b) => window.api.utils.compareVersions(a.version, b.version)).reverse();
4447
this.vzVersions.push(...versions.map(versionObject => {
4548
const label = versionObject.version;
4649
return { ...versionObject, label };

0 commit comments

Comments
 (0)