Serverless APIs With Ruby, AWS Lambda & AWS SAM CLI: Accessing Amazon RDS
- by Emre Yilmaz
- Jun 28, 2019
- AWS • Serverless • Ruby • DevOps • Databases • AWS Lambda • Amazon RDS • Amazon Aurora
Having a Ruby on Rails background, I got excited to try Ruby to code my AWS Lambda functions when its support for AWS Lambda was announced at Re:Invent 2018. Finally, to try Ruby on AWS Lambda, I developed a simple API using AWS Serverless Application Model (SAM) to access an Amazon RDS MySQL database. I wanted to compare it with my experiences of doing this with Python and Node.js.
Although it may seem simple, installing mysql2
gem as a dependency proved itself to be challenging than others, because it has native extensions and depends on the environment you use bundler
. As always, Docker simplifies our job by providing a similar environment that our AWS Lambda function runs inside.
In this post, I will make an introduction to AWS SAM CLI and using Ruby for AWS Lambda functions. Let’s begin!
Continue reading the Serverless APIs With Ruby, AWS Lambda & AWS SAM CLI: Accessing Amazon RDS blog post.