Minstel Minstel - 10 months ago 67
Node.js Question

Can not update lambda runtime through AWS CLI

I'm trying to update lambda runtime, using AWS CLI, with the following command:

aws lambda update-function-configuration --function-name <func_name> --runtime nodejs4.3

But I get an error:

Unknown options: --runtime, nodejs4.3

AWS version is as follows:
aws-cli/1.9.6 Python/3.5.0 Windows/7 botocore/1.3.6

Answer Source

The option is available from aws cli 1.10.19 so you need to upgrade at least to this version of newer

feature:lambda: Added support for setting the function runtime as nodejs4.3, as well as updating function configuration to set the runtime.

On Windows, download and run either the 64 bit installer (https://s3.amazonaws.com/aws-cli/AWSCLI64.msi) or the 32 bit installer (https://s3.amazonaws.com/aws-cli/AWSCLI32.msi).