mirror of
https://github.com/Kron4ek/Conty
synced 2024-12-27 09:58:25 +01:00
Add a delay before unmounting the image.
This should speed up Conty startup time significantly when executing multiple instances of Conty in a row.
This commit is contained in:
parent
c54e734987
commit
ba3737aa3d
1 changed files with 7 additions and 1 deletions
|
@ -762,7 +762,9 @@ run_bwrap () {
|
||||||
"$@"
|
"$@"
|
||||||
}
|
}
|
||||||
|
|
||||||
trap_exit () {
|
exit_function () {
|
||||||
|
sleep 5
|
||||||
|
|
||||||
rm -f "${working_dir}"/running_"${script_id}"
|
rm -f "${working_dir}"/running_"${script_id}"
|
||||||
|
|
||||||
if [ ! "$(ls "${working_dir}"/running_* 2>/dev/null)" ]; then
|
if [ ! "$(ls "${working_dir}"/running_* 2>/dev/null)" ]; then
|
||||||
|
@ -780,6 +782,10 @@ trap_exit () {
|
||||||
rm -rf "${working_dir}"
|
rm -rf "${working_dir}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
trap_exit () {
|
||||||
|
exit_function &
|
||||||
|
|
||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue