Skip to content

deniojunior/py-chassis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Py-chassis

CircleCI

Provides a chassis to build Python Micro-services

API Doc: https://app.swaggerhub.com/apis/deniojunior/py-chassis


Configuration

A file named config.yaml must be created in the root folder containing the following configuration:

name: [PROJECT_NAME]

Development

Next install dependencies using the following command for Pipfile:

pipenv sync --dev --three

To run the application, you must use the following command:

pipenv run python run.py -c config.yaml

It's also possible to start the application with gunicorn:

pipenv run gunicorn -w 2 --timeout 3600 -b 0.0.0.0:8080 "app.server:create_app(config='config.yaml')"

Tests

To run tests, at project path, execute:

pipenv run coverage run --omit="tests/*" --include="app/*" --branch -m unittest discover -s tests/unit -p "*_test.py"

Docker

Build docker image:

docker build -t py-chassis .

Run docker container:

docker container run -p 80:8080 -d --name microserivce py-chassis

About

Python Microservice Chassis

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published