Skip to content

ziad40/gard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gard Inventory Management System

Gard is an inventory management system built with FastAPI, SQLModel, and MySQL. It allows stores to manage categories, products, and inventory processes, with history tracking and media uploads.

Tech Stack

Python FastAPI Docker MySQL

Features

  • Branch authentication and registration
  • Category and product management with custom ordering
  • Inventory process tracking (start, continue, finish)
  • History of inventory operations
  • Media upload and retrieval for product images
  • RESTful API with OpenAPI docs

Development Setup

  1. Clone the repository

    git clone https://github.com/yourusername/gard.git
    cd gard
  2. Create and configure .env file

    MYSQL_USER=youruser
    MYSQL_PASSWORD=yourpassword
    MYSQL_HOST=db
    MYSQL_PORT=3306
    MYSQL_DB=garddb
    SECRET_KEY=your_secret_key
    ALGORITHM=HS256
    UPLOADS=/uploads
    BASE_URL=http://localhost:8000/
    
  3. Build and run with Docker Compose

    docker-compose up --build
  4. Access API docs

Project Structure

Production Deployment

  1. Configure server and secrets

  2. Push to main branch

    • The GitHub Actions workflow will deploy your code to the server, rebuild containers, and restart the app.
  3. Persistent uploads

    • The uploads folder is mounted as a Docker volume for persistent media storage.

API Workflow

  1. Login/Register branch
  2. Manage categories and products
  3. Start and process inventory
  4. View history and continue unfinished inventories
  5. Upload and fetch product images

For more details, see the API documentation at http://localhost:8000/docs.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published