使用AWS-Amplify->“放大推送”无效

时间:2019-06-09 09:02:17

标签: javascript amazon-web-services aws-amplify

要了解如何使用AWS-Amplify,我正在关注this document

一切正常,除非执行以下命令:

$ amplify push

它的结束是这样的:

Following resources failed

Resource Name: PinpointFunction (AWS::Lambda::Function)
Event Type: create
Reason: The runtime parameter of nodejs6.10 is no longer supported 
for creating or updating AWS Lambda functions. We recommend you use 
the new runtime (nodejs8.10) while creating or updating functions. 
(Service: AWSLambdaInternal; Status Code: 400; 
Error Code: InvalidParameterValueException; Request ID: xxxx-8a8e-.....-yyyy-zzzz)

✖ An error occurred when pushing the resources to the cloud

Resource is not in the state stackUpdateComplete

为什么会出现此错误?我过去已经运行过相同的命令。而且我没有更改我的NodeJS版本。

1 个答案:

答案 0 :(得分:0)

在Amplify CLI中,对节点6.10的所有引用应已更新为8.10。您将在当前配置中寻找的大多数参考应该在cloudformation文件中,它们是json或yml。您可以手动更改这些引用并进行推送,并且如果您安装了最新版本的CLI,那么以后应该没问题。