claudiajs : https://claudiajs.com
- install claudia
- execute command
npm init
- make lambda.js
- set aws credential on user root path
- create lambda function as command with profile
- invoke lambda with profile :
claudia test-lambda --profile claudia
- update lambda :
claudia update
- mongodb example project
install claudia
1 | # global installation |
make lambda project
1 | mkdir example |
make a lambda.js file : https://docs.aws.amazon.com/lambda/latest/dg/nodejs-prog-model-handler.html
1 | // 1.normal example |
setting AWS IAM
- https://claudiajs.com/tutorials/installing.html
- https://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/setting-credentials-node.html
make file .aws/credentials
first line is profile name.
1 | [claudia] |
create lambda function
seoul region is ap-northeast-2
.
1 | # create lambda |
invoke lambda
1 | #'test-' prefix is required. |
update lambda with npm run command
package.json
1 | ... |
update command : npm run deploy