The child_process module provides the ability to spawn child processes in a manner that is similar, but not identical, to popen(3).
Spawns a shell then executes the command within that shell, buffering any generated output.
Spawns a shell then executes the command within that shell, buffering any generated output.
Note: Never pass unsanitized user input to this function. Any input containing shell meta-characters may be used to trigger arbitrary command execution.
Fork Options
Fork Options
Spawn Options
Spawn Options
ChildProcess Singleton
ChildProcess Singleton
The child_process module provides the ability to spawn child processes in a manner that is similar, but not identical, to popen(3). This capability is primarily provided by the child_process.spawn() function.
https://nodejs.org/api/child_process.html