I am working on AWS lambda continuous integration and deployment. I have lambda's written in NodeJs and kept in Bitbucket repo. I am not able to find detailed tutorial or example to deploy those lambda's on AWS instance. AWS code pipeline source allows GitHub but not BitBucket. Any one has any idea how to do it. Please do share information or links if available.
3 Answers
You are right AWS code pipeline does not have bitbucket as the source provider.The option which looks possible is to configure bitbucket to copy the code to an AWS S3 bucket and then deploy the code from AWS S3. The source providers in AWS Code pipeline are:
- AWS S3
- AWS CodeCommit
- Github
You can use a zapier template to copy the bitbucket changes to S3.
Comments
Another solution, which does not depend on any AWS services except Lambda, is to include a Lambda deployment tool from the Bitbucket Pipeline. For this, my weapon of choice would be Claudia.js. As Claudia.js is based on Node.js and you probably have Node already in your pipeline image, it should be pretty easy to get started with it.