"tests/L1/git@developer.sourcefind.cn:OpenDAS/apex.git" did not exist on "86bd6c79decc9c7aba47f21855d3ead1d686e3b4"
Unverified Commit 4fc34df7 authored by J-shang's avatar J-shang Committed by GitHub
Browse files

Fix sharedstorage bug (#3426)

parent 99e2991a
...@@ -838,14 +838,14 @@ localMountPoint ...@@ -838,14 +838,14 @@ localMountPoint
Required. String. Required. String.
The absolute path that the storage has been or will be mounted in local. The absolute or relative path that the storage has been or will be mounted in local. If the path does not exist, it will be created automatically. Recommended to use an absolute path. i.e. ``/tmp/nni-shared-storage``.
remoteMountPoint remoteMountPoint
^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^
Required. String. Required. String.
The absolute path that the storage will be mounted in remote. The absolute or relative path that the storage will be mounted in remote. If the path does not exist, it will be created automatically. Note that the directory must be empty if using AzureBlob. Recommended to use a relative path. i.e. ``./nni-shared-storage``.
localMounted localMounted
^^^^^^^^^^^^ ^^^^^^^^^^^^
......
...@@ -148,6 +148,7 @@ common_schema = { ...@@ -148,6 +148,7 @@ common_schema = {
Optional('localMountPoint'): setType('localMountPoint', str), Optional('localMountPoint'): setType('localMountPoint', str),
Optional('remoteMountPoint'): setType('remoteMountPoint', str), Optional('remoteMountPoint'): setType('remoteMountPoint', str),
Optional('nfsServer'): setType('nfsServer', str), Optional('nfsServer'): setType('nfsServer', str),
Optional('exportedDirectory'): setType('exportedDirectory', str),
Optional('storageAccountName'): setType('storageAccountName', str), Optional('storageAccountName'): setType('storageAccountName', str),
Optional('storageAccountKey'): setType('storageAccountKey', str), Optional('storageAccountKey'): setType('storageAccountKey', str),
Optional('containerName'): setType('containerName', str), Optional('containerName'): setType('containerName', str),
......
...@@ -182,7 +182,7 @@ export class OpenPaiEnvironmentService extends EnvironmentService { ...@@ -182,7 +182,7 @@ export class OpenPaiEnvironmentService extends EnvironmentService {
let environmentRoot: string; let environmentRoot: string;
if (environment.useSharedStorage) { if (environment.useSharedStorage) {
environmentRoot = component.get<SharedStorageService>(SharedStorageService).remoteWorkingRoot; environmentRoot = component.get<SharedStorageService>(SharedStorageService).remoteWorkingRoot;
environment.command = `${component.get<SharedStorageService>(SharedStorageService).remoteMountCommand} && cd ${environmentRoot} && ${environment.command}`; environment.command = `${component.get<SharedStorageService>(SharedStorageService).remoteMountCommand.replace(/echo -e /g, `echo `).replace(/echo /g, `echo -e `)} && cd ${environmentRoot} && ${environment.command}`;
} else { } else {
environmentRoot = `${this.paiTrialConfig.containerNFSMountPath}/${this.experimentId}`; environmentRoot = `${this.paiTrialConfig.containerNFSMountPath}/${this.experimentId}`;
environment.command = `cd ${environmentRoot} && ${environment.command}`; environment.command = `cd ${environmentRoot} && ${environment.command}`;
......
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