Zinoma does not properly kill child processes.
- These processes can keep running after Zinoma shut down.
- These processes can stack up in watch mode.
This issue can be circumvented by adding exec in front of the problematic commands. For instance:
targets:
my_target:
service: exec ping github.com
It seems like the proper solution would be to start a new process group in the child process (using setpgid()) before running the script.
Then, the process group could be killed with kill(-pid).
This was successfully implemented by watchexec: https://github.com/watchexec/watchexec/blob/5843deb5732f1e92ad7b6775f52de7c8be063f6c/src/process.rs
Zinoma does not properly kill child processes.
This issue can be circumvented by adding
execin front of the problematic commands. For instance:It seems like the proper solution would be to start a new process group in the child process (using
setpgid()) before running the script.Then, the process group could be killed with
kill(-pid).This was successfully implemented by
watchexec: https://github.com/watchexec/watchexec/blob/5843deb5732f1e92ad7b6775f52de7c8be063f6c/src/process.rs