Skip to content

Commit f7d58b3

Browse files
committed
iJBDS-4186 Mark oc as executable on macOS and Linux
1 parent 119b546 commit f7d58b3

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

browser/model/cdk.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,10 @@ class CDKInstall extends InstallableItem {
120120
'oc.binary.path=' + this.installerDataSvc.ocDir(),
121121
'rhel.subscription.username=' + this.installerDataSvc.getUsername()
122122
].join('\r\n');
123-
123+
let ocDir = this.installerDataSvc.ocDir();
124124
installer.unzip(this.cdkDownloadedFile, this.installerDataSvc.installDir())
125-
.then((result) => { return installer.unzip(this.ocDownloadedFile, this.installerDataSvc.ocDir(), result); })
125+
.then((result) => { return installer.unzip(this.ocDownloadedFile, ocDir, result); })
126+
.then((result) => { return Platform.OS === 'win32' ? Promise.resolve(true) : installer.exec(`chmod +x ${ocDir}/oc`)})
126127
.then((result) => { return installer.copyFile(this.cdkBoxDownloadedFile, path.join(this.installerDataSvc.cdkBoxDir(), this.boxName), result); })
127128
.then((result) => { return Platform.OS === 'win32' ? installer.writeFile(this.pscpPathScript, data, result) : Promise.resolve(true); })
128129
.then((result) => { return installer.writeFile(this.installerDataSvc.cdkMarker(), markerContent, result); })

0 commit comments

Comments
 (0)