AWS lambda update-function-code with jar package via AWS CLI

与世无争的帅哥 提交于 2019-12-13 04:45:32

问题


I'm trying to update my lambda function code with jar from my local machine via AWS CLI. The aws lambda has commands to update function code for zip file but not for jar. I can upload by using s3 bucket, but I need to update from local itself.

I know following are the way to update from S3 bucket and for zip:

  1. aws lambda update-function-code --function-name --s3-bucket --s3-key
  2. aws lambda update-function-code --function-name --zip-file "fileb://"

I want to ask is there similar command exist for uploading jar as well?


回答1:


You're probably missing the "fileb://" part for the jar.

aws lambda update-function-code --function-name my-lambda-name --zip-file fileb://./target/my-lambda-jar.1.0-SNAPSHOT.jar


来源:https://stackoverflow.com/questions/49611739/aws-lambda-update-function-code-with-jar-package-via-aws-cli

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!