Skip to content
This repository has been archived by the owner on Jul 3, 2024. It is now read-only.

Cookiecutter serving as base for projects using tortoise (or any other ORM, really) with deployment configurations

License

Notifications You must be signed in to change notification settings

dymmond/esmerald-tortoise-nginx-gunicorn-supervisor

Repository files navigation

Cookiecutter NGINX, Supervisor, Docker, Gunicorn and Tortoise OR

Note

This repository was created before the Esmerald directives were created and added to its core.

Now that is in place for also quite some time, this repository no longer needs updating and you can also check an example using the directives about how to generate a similar project to this one.

Esmerald also became something bigger, better and with greater support so this repository no longer makes sense in bigger picture.

CI

Cookiecutter serving as base for projects using tortoise (or any other ORM, really) with deployment configurations


Table of Contents


Introduction

This cookiecutter served by Esmerald serves the purpose of a scaffold example for an application using:

Brings also an initial migration using Esmerald supported tables.

Requirements

  1. Python 3.8+.
  2. Esmerald.
  3. Virtual environment.
  4. Docker
  5. Cookiecutter

Instalation

$ cookiecutter https://github.com/dymmond/esmerald-tortoise-nginx-gunicorn-supervisor

After creating a virtual environment at your choice.

  1. make requirements - Installs the requirements to run the development environment.
  2. docker compose up - Starts the docker compose for databases and redis.
  3. make upgrade - Runs the migrations against the database.
  4. make run - Starts the development environment with the development settings.

You can now access the http://localhost:8000

INFO:     Uvicorn running on http://localhost:8000 (Press CTRL+C to quit)
INFO:     Started reloader process [28061] using WatchFiles
INFO:     Started server process [28063]
INFO:     Waiting for application startup.

Deployment

Every project has its own strategy but this cookiecutter brings a deployment folder containing all the files needed and prepared for the nginx, supervisor and gunicorn used for a deployment as well as a Dockerfile prepared to be built.

Endpoints

Once the cookiecutter is installed some endpoints can be use to verify if it is working.

OpenAPI

You can access the application docs via:

Disclaimer

This is not mandatory to be used and serves as quick entry point for applications that need to be deployed in a production environment and helps speeding up the process. Feel free to discard what is not needed.

About

Cookiecutter serving as base for projects using tortoise (or any other ORM, really) with deployment configurations

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published