An open-source inventory management system built with Wagtail CMS and Django. Manage products, stock levels, warehouses, purchases, and sales — all through Wagtail's powerful admin interface.
| Layer | Technology |
|---|---|
| Language | Python 3.12+ |
| Web framework | Django 6.0 |
| CMS / Admin UI | Wagtail 7.3 |
| Database | SQLite (dev) / PostgreSQL (production) |
| Search | Wagtail search backend (database or Elasticsearch) |
| Containerization | Docker |
For detailed environment configuration (local, Docker, production), see the Environment Configuration Guide.
- Python 3.12 or later
- Git
git clone https://github.com/Ndevu12/the_inventory.git
cd the_inventorypython -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activatepip install -r requirements.txtDjango’s manage.py and the project package live under src/. The repository root also holds seeders/ and tests/; run Django from src so imports resolve correctly (this matches CI and Docker).
cd srcpython manage.py migrateEnable full-text search functionality by indexing all searchable models (Products, Categories, Stock Locations):
python manage.py update_indexSeed the database with sample data for testing and development. By default, this creates a "Default" tenant and seeds all data to it:
python manage.py seed_database --clear --create-defaultFor multi-tenant setups or to seed a specific tenant, see the Seeding Guide.
python manage.py createsuperuserpython manage.py runserverVisit http://localhost:8000 for the site, or http://localhost:8000/admin/ for the Wagtail admin.
The image copies the full repository to /app, sets PYTHONPATH=/app/src:/app, and the entrypoint runs migrations and Gunicorn from /app/src (same layout as local cd src).
Build and run using Docker:
docker build -t the_inventory .
docker run -p 8000:8000 the_inventoryOptional database seeding on container start uses environment variables (not extra CLI arguments to gunicorn). Example:
docker run -p 8000:8000 -e AUTO_SEED_DATABASE=true -e DATABASE_URL=… the_inventoryFor complete environment variable documentation and deployment guides (Docker, Render, K8s), see the Environment Configuration Guide. Quick reference also in .env.example (section AUTO-SEED), seeders/README.md.
src/
├── manage.py # Django entry point (run commands from this directory)
├── the_inventory/ # Project configuration (settings, URLs, WSGI)
│ ├── settings/
│ ├── templates/
│ └── static/
├── api/, home/, inventory/, procurement/, reports/, sales/, search/, tenants/ # Django apps
└── locale/ # Backend translation catalogs
seeders/ # Seeding app (management commands) — repo root
tests/ # Test suite — repo root
frontend/ # Next.js tenant UI
docs/ # Project documentation (Architecture, Roadmap)
See Architecture for the full technical design, including the Phase 1 schema and app boundaries.
- Environment Configuration Guide — Complete environment variables and setup for all deployment contexts
- Architecture — Technical design and system overview
- Seeding Guide — Quick reference for tenant-scoped database seeding
- Seeder Documentation — Comprehensive seeding system documentation
- Roadmap — Development roadmap and phases
- Contributing Guide — How to contribute
- Code of Conduct — Community guidelines
- Changelog — Release history
Contributions are welcome! Please read our Contributing Guide before submitting a pull request.
This project follows the Contributor Covenant Code of Conduct.
Our CI workflow runs on pushes and pull requests to main and develop, and will:
- Set
PYTHONPATHto<repo>/src:<repo>(soseedersandtestsimport correctly) - From
src/(i.e.working-directory: srcin the workflow):- Run
python manage.py check - Run
python manage.py test tests - Run
python manage.py makemigrations --check --dry-run
- Run
- From the repo root:
ruff check src tests
You can mirror that locally from the repository root: cd src for Django commands, then ruff check src tests after cd .. (or open a second shell). If you change code under seeders/, also run ruff check seeders. Install dev tools from requirements-dev.txt. See Contributing for a full copy-paste checklist, including docker build.
This project is licensed under the BSD 3-Clause License — see the LICENSE file for details.
Copyright (c) 2026, Jean Paul Elisa NIYOKWIZERWA.