isolate doesn't use passed home dir if ran from su
shadowninja55 opened this issue · 2 comments
shadowninja55 commented
steps:
su
isolate --init
isolate --dir=/home/foo/bar --env=HOME=/box --run /bin/ls ~/bar
result:
/bin/ls: cannot access '/root/bar': No such file or directory
it also seems that even if i hardcode in /box/bar
to the ls part the directory is still not there. so perhaps it's neither mouting nor setting HOME.
gollux commented
The ~/bar
is expanded by the shell from which you run isolate
.
/box/bar
should not contain the home directory, it should be visiable as /home/foo/bar
inside the sandbox.
shadowninja55 commented
ah, that was the issue, thanks a lot!