Skip to main content

Simple example using Flask and Swagger powered by gunicorn.

Project description

gunicorn-flask-swagger-example

Downloads

git clone https://github.com/danielef/gunicorn-flask-swagger-example.git

Development

First, create a virtual environment as follows:

cd gunicorn-flask-swagger-example
virtualenv -p python3.7 env
source env/bin/activate

Then, install using pip:

pip install .

And run it with:

gsfe

Display all the options with -h:

$ gfse -h
usage: gfse [-h] [-b HOST] [-p PORT] [-v] [-r]

optional arguments:
  -h, --help            show this help message and exit
  -b HOST, --host HOST  APIn Host
  -p PORT, --port PORT  API Port
  -v, --verbose         API debug
  -r, --use-reloader    API use reloader

Running with gunicorn

gunicorn -w 4 gfse.app:app

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gunicorn-flask-swagger-example-0.0.2.tar.gz (5.3 kB view hashes)

Uploaded Source

Built Distribution

gunicorn_flask_swagger_example-0.0.2-py2.py3-none-any.whl (5.4 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page