Parameter to clear all environment variables
In our use case, we have a full environment defined for a container. We want to define only those and we do want to inherit any environment variable from host.
The current way to do it is to add --unsetenv parameters for every environment variable from host, before --setenv parameters.
This use case should be frequent enough for a --clearenv parameter to exist. This parameter would remove all environment variables. The command line would not need to depend on host environment variables.
This should be straightforward to implement. Are you intending to submit a merge request for this?
I was not intending to, unless nobody does it. Go ahead if you want.
In our use case, we have a full environment defined for a container. We want to define only those and we do want to inherit any environment variable from host.
what about "env -i" before invoking bwrap?
PR #401 added a --clearenv option, which was released in v0.5.0. I think this issue can be closed.