"...targets/git@developer.sourcefind.cn:gaoqiong/migraphx.git" did not exist on "ad056b1f87de1aa4d2c25b4e008d0d790a781620"
Unverified Commit b0732e01 authored by Yuge Zhang's avatar Yuge Zhang Committed by GitHub
Browse files

Refactor integration test (step 3) - Azure blob mount robustness (#4894)

parent 91a68821
...@@ -155,16 +155,17 @@ export class AzureBlobSharedStorageService extends SharedStorageService { ...@@ -155,16 +155,17 @@ export class AzureBlobSharedStorageService extends SharedStorageService {
return Promise.reject(errorMessage); return Promise.reject(errorMessage);
} }
try { // FIXME: This has security risks. The command might contain secrets.
this.log.debug(`Local mount command is: ${this.localMountCommand}`); this.log.debug(`Local mount command is: ${this.localMountCommand}`);
const result = await cpp.exec(this.localMountCommand); const result = await cpp.exec(this.localMountCommand);
if (result.stderr) { if (result.stderr) {
throw new Error(result.stderr); // FIXME: I don't know how to check whether it failed.
} // But looking at stderr definitely isn't a good idea.
} catch (error) { this.log.warning(
const errorMessage: string = `${this.storageType} Shared Storage: Mount ${this.storageAccountName}/${this.containerName} to ${this.localMountPoint} failed, error is ${error}`; `${this.storageType} Shared Storage: Mount ${this.storageAccountName}/${this.containerName} to ${this.localMountPoint}. Stderr is not empty.`
this.log.error(errorMessage); );
return Promise.reject(errorMessage); this.log.warning(`Stdout: ${result.stdout}`);
this.log.warning(`Stderr: ${result.stderr}`);
} }
return Promise.resolve(); return Promise.resolve();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment