Reputation: 5944
I am unable to update my AWS Lambda function using the CLI command,
I created a .zip file and uploaded the .zip to the Lambda function via the AWS Console and it worked,
But the same file I am not able to upload using the AWS CLI,
I am getting the following error while, trying to use the cli command -
Error parsing parameter '--zip-file': Unable to load paramfile fileb:
Command used to update the function -
aws lambda update-function-code --function-name test --zip-file "fileb://$deployableName"
I am referring the following links -
1. https://docs.aws.amazon.com/cli/latest/reference/lambda/update-function-code.html
2. AWS lambda update-function-code with jar package via AWS CLI
3. How can I create an AWS Lambda function using the AWS CLI?
Upvotes: 2
Views: 3095
Reputation: 8140
The error
Error parsing parameter '--zip-file': Unable to load paramfile fileb:
Indicates that the given file can not be found. Are you sure that:
Upvotes: 0
Reputation: 5944
I was able to resolve this by specifying the absolute path of the .zip file
,
to the --zip-file option.
aws lambda update-function-code --function-name test --zip-file "fileb:///home/user/poc/lambda/Monday-17-Jun-2019-1560756274.zip"
Upvotes: 3