我们正在使用AWS Toolkit Visual Studio 2017(“https://aws.amazon.com/blogs/developer/preview-of-the-aws-toolkit-for-visual-studio-2017/”)来创建AWS无服务器lambda。当我们部署这个lambda函数时,我们得到状态:“UPDATE_ROLLBACK_Complete”
这是我们的serverless.template文件:
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Transform" : "AWS::Serverless-2016-10-31",
"Description" : "An AWS Serverless Application that uses the ASP.NET Core framework running in Amazon Lambda.",
"Parameters" : {
},
"Conditions" : {
},
"Resources" : {
"Get" : {
"Type" : "AWS::Serverless::Function",
"Properties": {
"Handler": "F2C.MAP.API.AWSLambda.IdentityServer::F2C.MAP.API.AWSLambda.IdentityServer.LambdaEntryPoint::FunctionHandlerAsync",
"Runtime": "dotnetcore2.0",
"CodeUri": "",
"FunctionName":"CreateToken",
"Description":"Create access token based on clientId and client secret",
"MemorySize": 256,
"Timeout": 30,
"Role": null,
"Policies": [ "AWSLambdaFullAccess" ],
"Environment" : {
"Variables" : {
}
},
"VpcConfig":{
"SecurityGroupIds":["sg-123456"],
"SubnetIds":["subnet-123456"]
},
"Events": {
"PutResource": {
"Type": "Api",
"Properties": {
"Path": "/{proxy+}",
"Method": "GET"
}
}
}
}
}
},
"Outputs" : {
}
}