https://github.com/tleonhardt/serverless-flask
Serverless Framework Flask application
https://github.com/tleonhardt/serverless-flask
Last synced: 6 months ago
JSON representation
Serverless Framework Flask application
- Host: GitHub
- URL: https://github.com/tleonhardt/serverless-flask
- Owner: tleonhardt
- Created: 2020-04-14T00:35:07.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-10-25T19:26:22.000Z (over 2 years ago)
- Last Synced: 2024-12-28T10:52:23.753Z (over 1 year ago)
- Language: Python
- Size: 78.1 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Serverless Flask Application
This is code which follows the tutorial
[Build a Python REST API with Serverless, Lambda, and DynamoDB](https://serverless.com/blog/flask-python-rest-api-serverless-lambda-dynamodb/)
to create a deploy a serverless REST API using [Serverless Framework](https://github.com/serverless/serverless) and
[Flask](https://flask.palletsprojects.com).
## Prerequisites
### JavaScript
```shell script
npm install
sls dyanamodb install
```
### Python
```shell script
pipenv install
pipenv shell
```
## Run Flask App locally
```shell script
pipenv shell
python app.py
```
## Deploy to AWS
```shell script
sls deploy
```
## Local development configuration with Serverless offline plugin
In one terminal start the local DynamoDB emulator:
```shell script
sls dynamodb start
```
In another terminal start the local development environment
```shell script
sls wsgi serve
```