Skip to content

pablosilvab/delivery-serverless-aws

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Stargazers Issues

Delivery Serverless AWS

This project is an API for delivery built with Serverless framework in AWS infrastructure.

Tools

Node aws amazon-db

  • Serverless Framework
  • AWS Lambda
  • API Gateway
  • Simple Queue Service SQS
  • CloudFormation
  • AWS SDK

Requirements

  • Node.js
  • npm
  • Serverless framework
sudo npm install -g serverless

Deployment

  1. Make sure the credentials is set.
serverless config credentials --provider aws --key <access-key> --secret <secret-access>
  1. Deploy function
serverless deploy

Example

Request: POST

{
	"name": "Walter Hartwell White",
	"address": "308 Negra Arroyo Lane, Albuquerque, New Mexico, 87104",
	"pizzas": ["margarita", "napolitana"]
}

Remove project

For clean AWS account you should run:

sls remove

Issues

Watch logs in serverless framework

serverless logs -f makeOrder -t
  • It's important to make sure the yml file has the same localization region as your account.

Other

  • Same application with open source tools: (OpenFaaS, RabbitMQ y MySQL -> Kadev) 🚚🚚🚚