Mintfit

MintfitV2 Dashboard

System Overview & Monitoring

Development

System Health

Overall Status: Healthy

Last checked: 2026-07-06T13:28:12+00:00

Database

healthy

Database connection is healthy

Cache

healthy

Cache is healthy

Database Connection

Status
Connected
Database
mintfit
Host
mysql:3306
Version
11.8.5-MariaDB-ubu2404
Database Size
6.22 MB
Active Connections
2

Queue Metrics

Pending Jobs
0
Failed Jobs
0
Worker Status
Unknown

Project README

MintfitV2

A modern Learning Management System (LMS) built as a modular monolith with Laravel 12. Designed to replace Moodle with a flexible, API-driven architecture that maintains microservice-style boundaries while keeping deployment simple.

Key Features

  • API-Only Backend - Stateless JWT authentication, JSON responses
  • Modular Monolith - Self-contained modules with strict boundaries enforced by Deptrac
  • Docker-Based - Complete development environment with one command
  • Anonymous Sessions - Guest users can interact before registration
  • Multi-Tenancy - Built-in tenant isolation
  • RBAC - Role-based access control with flexible permission system

Architecture

Each module is a self-contained domain with clean separation:

modules/{ModuleName}/
├── Domain/           # Entities, DTOs, value objects
├── Application/      # Services (public API), use cases
└── Infrastructure/   # Repositories, controllers, models

Module Communication: Modules interact only via Service injection. Services return DTOs, never models.

Current Modules: Health, Tenant, Identity, User, Block, Notification, Dashboard

Quick Start

# Complete setup (first time)
make setup

# Start development environment
make start

Services:

Common Commands

# Development
make start              # Start all services
make logs               # View application logs
make shell              # Open shell in container

# Database
make db-migrate         # Run migrations
make db-seed            # Seed database
make db-reset           # Fresh database with seeds

# Testing & Quality
make test               # Run all tests
make analyze            # Run all checks (tests, pint, deptrac, phpstan)
make pint               # Format code
make deptrac            # Check module boundaries

# Modules
make module NAME=Product TYPE=stateful    # Generate new module
make module-test MODULE=Tenant            # Test specific module
make module-migrate MODULE=Tenant         # Migrate specific module

# View all commands
make help

Creating a New Module

# Interactive mode (recommended)
make module NAME=Product

# With options
make module NAME=Order TYPE=stateful WITH_EVENTS=1 WITH_TESTS=1

The generator creates:

  • Complete module structure (Domain, Application, Infrastructure)
  • DTOs with validation rules
  • Service with CRUD operations
  • Repository and Model
  • Controller and routes
  • Migration and seeder
  • Tests (Feature and Unit)
  • Permission provider (stateful modules)

After generation:

  1. Customize DTOs and validation rules
  2. Update migration schema
  3. Configure permissions in config/module_rbac.php
  4. Run make module-migrate MODULE=YourModule
  5. Run make module-test MODULE=YourModule

Git Hooks

Pre-commit hooks enforce code quality automatically before each commit:

  • Laravel Pint - Enforces PSR-12 code style
  • Deptrac - Validates module boundaries
  • PHPStan - Static analysis (level 5)

Installation:

make install-hooks

The hooks are stored in .githooks/ and symlinked to .git/hooks/. If any check fails, the commit is blocked.

Bypass (not recommended):

git commit --no-verify

See .githooks/README.md for more details.

Documentation

  • CLAUDE.md - Complete project documentation (architecture, patterns, commands)
  • CONTRIBUTING.md - Module system rules and conventions
  • API Documentation - Auto-generated, view at /docs endpoint

Technology Stack

  • Framework: Laravel 12 (PHP 8.2+)
  • Database: MariaDB 11
  • Cache/Queues: Redis
  • Authentication: JWT (stateless)
  • Frontend: Tailwind CSS 4, Vite
  • Testing: PHPUnit with SQLite
  • API Docs: Scribe
  • Architecture Enforcement: Deptrac, PHPStan

Development Workflow

  1. Understand the architecture - Read CONTRIBUTING.md
  2. Explore existing modules - Look at Health, Tenant, or Block for patterns
  3. Create or modify modules - Use make module or follow existing patterns
  4. Test your changes - Write tests, run make test
  5. Verify quality - Run make analyze before committing

Architecture Enforcement

Deptrac enforces module boundaries:

  • Modules can ONLY access other modules via Services
  • No direct access to Repositories, Models, or Infrastructure
  • Layered architecture: Domain → Application → Infrastructure

PHPStan ensures type safety and catches bugs before runtime.

Run make analyze to verify both.

Important Notes

  • This is NOT standard Laravel - Strict module boundaries enforced
  • All authentication is stateless JWT (no sessions)
  • Services are the public API for modules
  • Always return DTOs from Services, never models
  • Use ULIDs for primary keys (via HasUlids trait)
  • API-only - No Blade views or traditional forms (except Dashboard module for internal monitoring)

License

Proprietary - All rights reserved

System Overview

Modules
25
Database Tables
57
Routes
348
Tests
126
Pending Jobs
0
Failed Jobs
0
Custom Commands
16

Detailed Statistics

Table Row Counts

Table Rows
permissions 296
attempt_slot_history 259
attempt_scheduled_slots 256
role_permissions 248
attempt_responses 130
quiz_slot_options 115
migrations 71
questions_history 71
quiz_slots 65
attempts 61
questions 44
identities 30
notifications 30
quiz_sections 24
quiz_versions 24
content_history 23
quizzes 20
roles 16
media 13
contents 12
role_user 10
placements 8
certificate_definitions 5
tags 4
manual_grading_assignments 3
tag_contexts 3
certificates 2
ad_clicks 0
ad_impressions 0
ad_placements 0
ad_statistics 0
ads 0
ads_history 0
anonymous_sessions 0
cache 0
cache_locks 0
content_progress 0
course_activities 0
course_activity_progress 0
course_enrollments 0
courses 0
failed_jobs 0
media_aliases 0
media_conversions 0
moodle_import_mappings 0
moodle_import_runs 0
notification_preferences 0
tag_assignments 0
telescope_entries 0
telescope_entries_tags 0

Routes by Module

Quiz 35
Core 33
Content 32
Course 24
Ads 23
User 21
Question 20
Media 19
Rbac 18
Certificate 16
Notification 13
Attempt 11
Evaluation 11
Tag 11
Tenant 9
Block 8
Identity 8
Pdf 7
Verification 7
Transfer 7
Statistics 5
Metrics 4
Dashboard 3
MoodleImport 2
Health 1

Tests by Module

Evaluation 27
Block 11
Quiz 9
MoodleImport 8
Identity 7
Question 7
Rbac 7
Certificate 5
Tenant 5
Attempt 4
Content 4
Course 4
Media 4
User 4
Ads 3
Notification 3
Tag 3
Transfer 3
Cas 2
Dashboard 1
Health 1
Metrics 1
Pdf 1
Statistics 1
Verification 1