runme icon indicating copy to clipboard operation
runme copied to clipboard

Collecting envs needs improvement

Open adambabik opened this issue 2 years ago • 1 comments

The current env detection is very naive:

  • It uses env > file for the env snapshot before running the command and the same for the env snapshot after.
  • It does not work well if a command is interrupted or fails; consider using trap instead.
  • It dumps env on a disk; it would be much better to avoid that. Maybe use some IPC?

adambabik avatar Feb 22 '23 17:02 adambabik

It dumps env on a disk; it would be much better to avoid that.

@sourishkrout @mxsdev If we don't know a simple and reliable way to avoid this at the moment, we can at least encrypt what is being dumped. An encryption key can be generated and stored in memory while a request is being processed. This should be fairly easy to implement and it will greatly improve the situation.

adambabik avatar Feb 24 '23 08:02 adambabik