On Mon, 12 May 2014 19:39:09 +0200
Michał Górny <mgo...@gentoo.org> wrote:

> I don't know postgresql well enough but does the test db reside
> in temporary build directory? That is, can you guarantee that:
> 
> 1) it will never ever collide with user's database,
> 
> 2) it will be properly cleaned up even if the test suite terminates
> unexpectedly?

The closest thing you could do would be to create a separate tablespace
residing in the build directory. I wouldn't consider this a good idea
however, as you'd need postgres superuser permissions, it would have
some unintented side effects (like breaking on SELinux machines), you'd
have to patch the test suites and it still wouldn't ensure an automatic
cleanup -- on unexpected test suite terminations the dir in which the
tablespace resides would vanish, but postgres would still expect one
there, which might even create further problems (especially on
re-emerge). I wouldn't recommend using this approach even when
accessing the host postgres.

On top of that, many postgres installations with reasonably secure
configuration wouldn't grant portage access anyway.

As it isn't hard at all to run a separate postgres instance (upstream
is explicitly supporting it), I'd strongly recommend doing so even with
network-sandbox being disabled.


--
Regards,
Luis Ressel

Attachment: signature.asc
Description: PGP signature

Reply via email to