diff --git a/remount-fuse.sh b/remount-fuse.sh index 002878d..ca2ccc9 100644 --- a/remount-fuse.sh +++ b/remount-fuse.sh @@ -21,15 +21,6 @@ case "$install_dir" in ''|/|*[![:print:]]*) die 'installation directory is inval [ -d "$install_dir" ] || die "installation directory does not exist: $install_dir" install_dir=$(CDPATH='' cd -- "$install_dir" && pwd -P) || die 'cannot canonicalize installation directory' [ "$(id -u)" -eq 0 ] || die 'FUSE maintenance requires root (euid 0)' -INSTALL_PATH="$install_dir" python3 - <<'PY' || die 'installation directory must be root-owned and not group/world writable' -import os, pathlib, stat -path = pathlib.Path(os.environ['INSTALL_PATH']) -info = path.lstat() -# Parent directories may belong to the account that owns the home directory. -# The installation directory and protected files remain root-owned below. -if info.st_uid != 0 or info.st_mode & 0o022: - raise SystemExit(1) -PY [ -f "$install_dir/.env" ] || die "missing $install_dir/.env" [ -f "$install_dir/compose.yaml" ] || die "missing $install_dir/compose.yaml" [ -f "$install_dir/config.yaml" ] || die "missing $install_dir/config.yaml"