Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
nni
Commits
ae36373c
Unverified
Commit
ae36373c
authored
Nov 22, 2019
by
SparkSnail
Committed by
GitHub
Nov 22, 2019
Browse files
Fix copy commands (#1763)
parent
3caf4cec
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
src/nni_manager/training_service/common/util.ts
src/nni_manager/training_service/common/util.ts
+1
-1
src/nni_manager/training_service/remote_machine/remoteMachineTrainingService.ts
...ng_service/remote_machine/remoteMachineTrainingService.ts
+1
-1
No files found.
src/nni_manager/training_service/common/util.ts
View file @
ae36373c
...
@@ -89,7 +89,7 @@ export async function execCopydir(source: string, destination: string): Promise<
...
@@ -89,7 +89,7 @@ export async function execCopydir(source: string, destination: string): Promise<
if
(
process
.
platform
===
'
win32
'
)
{
if
(
process
.
platform
===
'
win32
'
)
{
await
cpp
.
exec
(
`powershell.exe Copy-Item "
${
source
}
" -Destination "
${
destination
}
" -Recurse`
);
await
cpp
.
exec
(
`powershell.exe Copy-Item "
${
source
}
" -Destination "
${
destination
}
" -Recurse`
);
}
else
{
}
else
{
await
cpp
.
exec
(
`cp -r '
${
source
}
' '
${
destination
}
'`
);
await
cpp
.
exec
(
`cp -r '
${
source
}
/.
' '
${
destination
}
'`
);
}
}
return
Promise
.
resolve
();
return
Promise
.
resolve
();
...
...
src/nni_manager/training_service/remote_machine/remoteMachineTrainingService.ts
View file @
ae36373c
...
@@ -599,7 +599,7 @@ class RemoteMachineTrainingService implements TrainingService {
...
@@ -599,7 +599,7 @@ class RemoteMachineTrainingService implements TrainingService {
await
execMkdir
(
path
.
join
(
trialLocalTempFolder
,
'
.nni
'
));
await
execMkdir
(
path
.
join
(
trialLocalTempFolder
,
'
.nni
'
));
//create tmp trial working folder locally.
//create tmp trial working folder locally.
await
execCopydir
(
path
.
join
(
this
.
trialConfig
.
codeDir
,
'
*
'
),
trialLocalTempFolder
);
await
execCopydir
(
this
.
trialConfig
.
codeDir
,
trialLocalTempFolder
);
const
installScriptContent
:
string
=
CONTAINER_INSTALL_NNI_SHELL_FORMAT
;
const
installScriptContent
:
string
=
CONTAINER_INSTALL_NNI_SHELL_FORMAT
;
// Write NNI installation file to local tmp files
// Write NNI installation file to local tmp files
await
fs
.
promises
.
writeFile
(
path
.
join
(
trialLocalTempFolder
,
'
install_nni.sh
'
),
installScriptContent
,
{
encoding
:
'
utf8
'
});
await
fs
.
promises
.
writeFile
(
path
.
join
(
trialLocalTempFolder
,
'
install_nni.sh
'
),
installScriptContent
,
{
encoding
:
'
utf8
'
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment