pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: stray files in go build / bob sandbox not empty



Jonathan Perkin <jperkin%pkgsrc.org@localhost> writes:

> * On 2026-07-09 at 23:21 BST, Greg Troxel wrote:
>
>>  go is escaping FAKE_HOME set up by pkgsrc
>
> Myself and wiz noticed something similar with I think cargo, and while
> I didn't fully debug it I think it's caused by tools going directly to
> getpwnam / pw_dir, so I'm not sure we can avoid it.

I guess $someone can fix go; telemetry is a serious bug anyway.

>>  some combination of leftover files in home and bob objecting to
>>  polluted sandoxes
>
> The way to clean this up in bob is to add a hook so that it's removed
> after every build, e.g.:
>
>   sandboxes = {
>     hooks = {
>       { action = "cmd",
>         destroy = "rm -rf ${bob_sandbox_path}/home/gdt/.config/go" },
>     }
>   }
>
> or similar.

Why doesn't sandbox deconfig work with the leftover crud that buggy
packages leave?    Perhaps some kind of lost+found to be nuked later, as
I would expect you don't want to rm.  I'm thinking of putting all that in

  now = time()
  ${bob_sandbox_path}/leftover/$now/

which still leaves them.

Another approach is just to ignroe the message; it seems to not stop
the new sandbox use.

I also wonder about figuring out $HOME and/or getpwnam from real-uid and
mounting a fake-home tmpfs and then unmounting it.   Avoids having to
rm, while cleaning.


Home | Main Index | Thread Index | Old Index