Sanity check around child_process

Should the following work / does it work for anyone else if you swap ‘ping’ for a known working function that requires no event?

var exec = require('child_process').exec;

exec('serverless invoke local -f ping', function(err,stdout,stderr) {
    if (err) {throw err;}

I cannot seem to invoke serverless from child_process as I get an exception thrown even in this simplest possible test case I could create?

1 Like