On Fri, 09 Apr 2021 at 10:37:59 +0200, Laurent Bigonville wrote:
> The dep8 specification says:
> 
> Tests can expect that the ``$HOME`` environment variable to be set
> to a directory that exists and is writeable by the user running the test.
> 
> But when using schroot (not tried anythong else), $HOME is set to the
> HOME of the user running the autopkgtest and does not exists in the
> schroot. So either the spec is wrong or the implementation.

What schroot configuration are you using? Relevant information:

* your user's home directory
* the file in /etc/schroot/chroot.d defining the chroot you're using
* /etc/schroot/${profile}/fstab, where ${profile} is taken from the
  chroot's configuration

If you are using profile=default (which is the default if left unspecified),
/etc/schroot/default/fstab usually bind-mounts the real /home.

If you are using profile=sbuild, /etc/schroot/sbuild/fstab usually does
not, making it unsuitable for autopkgtest-virt-schroot.

Using a chroot that contains a pre-created home directory for the user
running autopkgtest is also an option, but this is not currently something
that can be set up automatically.

I would recommend using autopkgtest-virt-lxc or autopkgtest-virt-qemu:
those are considerably better-tested in practice than -schroot.

    smcv

Reply via email to