Skip to content

Full stack, modern web application template. Using FastAPI, Vuejs, MongoDB, PostgreSQL, Redis, Metabase, Grafana, Docker, and more!

License

Notifications You must be signed in to change notification settings

deepmancer/full-stack-fastapi-ftgo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ• Full-stack Microservice-Based Food Delivery Application

FastAPI Python Node.js Vue.js PostgreSQL MongoDB Redis SQLAlchemy Pydantic NGINX Docker RabbitMQ Prometheus Grafana Metabase YAML H3

FTGO is a scalable, microservice-based food ordering application built with Python (FastAPI) and Vue.js, designed following object-oriented design principles.

๐Ÿ’Ž You can use this project as a template to build your backend microservice project in Python ๐Ÿ’Ž

๐Ÿ”Š New features and technologies will be added soon!


Source Code: https://github.com/deepmancer/full-stack-fastapi-ftgo


๐Ÿ”ฅ Technology Stack and Features

  • โšก FastAPI:

    • ๐Ÿ”ฎ pydantic for settings and request/response validation.
    • ๐Ÿ”‘ JWT middleware for secure authentication.
    • ๐Ÿšง Permission manager for role-based access control on routes.
    • ๐Ÿ“› Rate limiting for API protection.
    • โŒš RequestId, Timing, and many exciting middlewares!
    • ๐Ÿ”’ Secure password hashing by default.
    • ๐ŸŒ€ Customizable profilers with Prometheus.
  • ๐ŸŒฑ MongoDB:

    • Async client with motor and Object Document Mapping (ODM) with beanie.
    • mongo-motors package for singleton and managed connection.
  • ๐Ÿงฐ Redis:

  • ๐Ÿ’พ PostgreSQL:

  • ๐Ÿš€ RabbitMQ:

  • ๐Ÿ‹ Docker Compose:

    • Containers for simplified deployment and scaling.
  • โœ… Pytest:

    • Async tests with pytest and pytest-async.

๐Ÿ“‚ GUI Management Tools

These tools are configured and run via Docker in the infra/admin/docker-compose.yaml.

Setup Instructions

Step 1: Create Docker Networks

Create Docker networks for backend and frontend services.

docker network create --driver bridge backend-network
docker network create --driver bridge frontend-network

Step 2: Build and Run Infrastructure

Navigate to the infrastructure directory and start the services, including databases and GUI tools.

cd backend/infra
docker compose up --build

Infrastructure Layout:

backend/infra
โ”œโ”€โ”€ admin (Metabase, RedisInsight, Mongo-Express)
โ”œโ”€โ”€ mongo
โ”œโ”€โ”€ monitoring (Grafana, Prometheus)
โ”œโ”€โ”€ postgres
โ”œโ”€โ”€ rabbitmq (with the Management extension)
โ””โ”€โ”€ redis

Step 3: Build and Run Microservices

Navigate to the backend directory and start all microservices.

cd backend/
docker compose up --build

Frontend Setup

The frontend is built with Vue.js for a dynamic and responsive user experience.

Step 1: Install Dependencies

Navigate to the ui/ directory and install the required packages.

cd ui/
npm install

Step 2: Start Development Server

Run the development server with hot-reloading enabled.

npm run serve

Interactive API Documentation

image

Admin Dashboards

Grafana (localhost:3000)

image

Metabase (localhost:3030)

image

RedisInsight (localhost:5540)

image

RabbitMQ Management (localhost:15673)

image

MongoDB Compass

image