fix recursive mount operations

Signed-off-by: Travis Glenn Hansen <travisghansen@yahoo.com>
This commit is contained in:
Travis Glenn Hansen 2025-01-22 21:29:51 -07:00
parent de242c2d7f
commit 93e0446fa3
5 changed files with 533 additions and 251 deletions

View File

@ -1,6 +1,7 @@
#!/usr/bin/env bash
P="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/run/current-system/sw/bin"
PL="/usr/sbin:/usr/bin:/sbin:/bin:/run/current-system/sw/bin"
container_supported_filesystems=(
"ext2"
@ -42,6 +43,6 @@ if [[ ${USE_HOST_MOUNT_TOOLS} -eq 1 ]]; then
chroot /host /usr/bin/env -i PATH="${P}" mount "${@:1}"
exit $?
else
/usr/bin/env -i PATH="${P}" mount "${@:1}"
/usr/bin/env -i PATH="${PL}" mount "${@:1}"
exit $?
fi

View File

@ -1,6 +1,7 @@
#!/usr/bin/env bash
P="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/run/current-system/sw/bin"
PL="/usr/sbin:/usr/bin:/sbin:/bin:/run/current-system/sw/bin"
container_supported_filesystems=(
"ext2"
@ -42,6 +43,6 @@ if [[ ${USE_HOST_MOUNT_TOOLS} -eq 1 ]]; then
chroot /host /usr/bin/env -i PATH="${P}" umount "${@:1}"
exit $?
else
/usr/bin/env -i PATH="${P}" umount "${@:1}"
/usr/bin/env -i PATH="${PL}" umount "${@:1}"
exit $?
fi

774
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -31,11 +31,13 @@
"lodash": "^4.17.21",
"lru-cache": "^7.4.0",
"prompt": "^1.2.2",
"reconnecting-websocket": "^4.4.0",
"semver": "^7.3.4",
"ssh2": "^1.1.0",
"uri-js": "^4.4.1",
"uuid": "^9.0.0",
"winston": "^3.6.0",
"ws": "^8.18.0",
"yargs": "^17.0.1"
},
"devDependencies": {

View File

@ -397,7 +397,7 @@ class Mount {
exec(command, args, options = {}) {
if (!options.hasOwnProperty("timeout")) {
options.timeout = DEFAULT_TIMEOUT;
options.timeout = parseInt(DEFAULT_TIMEOUT) || 30 * 1000;
}
const mount = this;