Invoking System Utilities
Explore how to invoke external system utilities in AWS Lambda functions using Node.js child_process with Promises. Understand how to modify function code to execute utilities like mogrify for image processing, and deploy changes with AWS SAM and CloudFormation. This lesson helps you extend Lambda's capabilities for asynchronous command execution and troubleshooting.
We'll cover the following...
We'll cover the following...
child_process #
Now that mogrify is available to your Lambda function, you can change the source code for the conversion function to execute it.
To start a command-line utility from JavaScript, you’ll need to use the Node.js child process features.
The spawn function from the Node.js child_process module uses callbacks. You ...