diff --git a/setup.sh b/setup.sh index 3038a418..679a3e9c 100755 --- a/setup.sh +++ b/setup.sh @@ -1,5 +1,5 @@ #!/bin/sh -wget https://github.com/ezrizhu/gidmapper/releases/download/0.0.3/gidmapper -O /usr/local/bin/gidmapper -chmod +x /usr/local/bin/gidmapper -setcap 'CAP_SETGID=ep' /usr/local/bin/gidmapper +wget https://github.com/ezrizhu/gidmapper/releases/download/0.0.3/gidmapper -O /usr/bin/gidmapper +chmod +x /usr/bin/gidmapper +setcap 'CAP_SETGID=ep' /usr/bin/gidmapper diff --git a/test/gidmapping.sh b/test/gidmapping.sh index a964584c..1415bbc8 100755 --- a/test/gidmapping.sh +++ b/test/gidmapping.sh @@ -4,7 +4,7 @@ TRY_TOP="${TRY_TOP:-$(git rev-parse --show-toplevel --show-superproject-working- TRY="$TRY_TOP/try" control=$(id -G) -testing=$("$TRY" id -G) +testing=$("$TRY" id -G 2>/dev/null) if [ "$control" = "$testing" ] then diff --git a/test/missing_unionfs_mergerfs.sh b/test/missing_unionfs_mergerfs.sh index a58c0142..38b3f305 100755 --- a/test/missing_unionfs_mergerfs.sh +++ b/test/missing_unionfs_mergerfs.sh @@ -27,15 +27,14 @@ try_workspace="$(mktemp -d)" cd "$try_workspace" || return 9 new_bin_dir="$(mktemp -d)" -mkdir -p "$new_bin_dir/usr/local" +mkdir "$new_bin_dir/usr" # -s makes symlinks cp -rs /usr/bin "$new_bin_dir/usr/bin" -cp -rs /usr/local/bin "$new_bin_dir/usr/local/bin" # Delete mergerfs and unionfs and set the new PATH to the temporary directory rm -f "$new_bin_dir/usr/bin/mergerfs" 2>/dev/null rm -f "$new_bin_dir/usr/bin/unionfs" 2>/dev/null echo hi >expected -PATH="$new_bin_dir/usr/bin:$new_bin_dir/usr/local/bin" "$TRY" -y "echo hi" >target 2>/dev/null || return 1 +PATH="$new_bin_dir/usr/bin" "$TRY" -y "echo hi" >target 2>/dev/null || return 1 diff -q expected target || return 2