OpenKMS is a comprehensive knowledge management system designed to streamline training administration, user management, and knowledge sharing within organizations. Built with modern web technologies, it provides a robust platform for managing training programs, user registrations, and learning resources.
- Training Management: Create, manage, and track training programs and schedules
- User Administration: Complete user lifecycle management with role-based access control
- Registration System: Streamlined training enrollment and attendance tracking
- Knowledge Base: Centralized repository for learning materials and documentation
- Admin Dashboard: Comprehensive dashboard for system administration and analytics
- Modern UI/UX: Responsive web interface built with Blazor Server and Bootstrap
- RESTful API: FastAPI backend with automatic API documentation
- Authentication & Authorization: JWT-based authentication with role-based permissions
- Database Management: PostgreSQL with async SQLAlchemy for optimal performance
- Caching Layer: Redis integration for improved performance
- Containerized: Docker-compose orchestration for easy deployment
- Docker 20.10+
- Docker Compose 2.0+
- Git
-
Clone the repository
git clone https://github.com/your-org/openkms.git cd openkms -
Set up environment
chmod +x scripts/*.sh ./scripts/check-environment.sh ./scripts/dev-setup.sh -
Start the application
./scripts/dev-commands.sh start
-
Access the application
- Frontend: http://localhost:8080
- Backend API: http://localhost:8000
- API Documentation: http://localhost:8000/docs
OpenKMS follows a modern microservices architecture with clear separation of concerns:
βββββββββββββββββββββββ βββββββββββββββββββββββ βββββββββββββββββββββββ
β Frontend β β Backend β β Infrastructure β
β β β β β β
β β’ Blazor Server βββββΊβ β’ FastAPI βββββΊβ β’ PostgreSQL β
β β’ Bootstrap UI β β β’ SQLAlchemy β β β’ Redis β
β β’ C#/.NET 8 β β β’ JWT Auth β β β’ Docker β
β β’ SignalR β β β’ Pydantic β β β’ Nginx (Prod) β
β β β β’ Alembic β β β
βββββββββββββββββββββββ βββββββββββββββββββββββ βββββββββββββββββββββββ
- Framework: ASP.NET Core 8 Blazor Server
- UI Framework: Bootstrap 5 with custom design system
- Language: C# 12
- Authentication: JWT tokens with local storage
- Communication: SignalR for real-time updates
- Framework: FastAPI 0.104+
- Language: Python 3.9+
- ORM: SQLAlchemy 2.0 with async support
- Authentication: JWT with Pydantic validation
- API Documentation: OpenAPI/Swagger auto-generated
- Database Migrations: Alembic
- Database: PostgreSQL 15
- Cache: Redis 7
- Containerization: Docker & Docker Compose
- Web Server: Nginx (Production)
- SSL/TLS: Let's Encrypt support
For detailed development instructions, see README.DEVELOPMENT.md.
# Start development environment
./scripts/dev-commands.sh start
# View logs
./scripts/dev-commands.sh logs
./scripts/dev-commands.sh logs-backend
./scripts/dev-commands.sh logs-frontend
# Run tests
./scripts/dev-commands.sh test-backend
./scripts/dev-commands.sh test-frontend
# Database operations
./scripts/dev-commands.sh migrate # Run migrations
./scripts/dev-commands.sh migrate-new # Create migration
./scripts/dev-commands.sh backup # Create backupopenkms/
βββ openkms-backend/ # Python FastAPI backend
β βββ app/
β β βββ core/ # Core configuration
β β βββ models/ # SQLAlchemy models
β β βββ schemas/ # Pydantic schemas
β β βββ api/ # API endpoints
β β βββ services/ # Business logic
β βββ tests/ # Test files
β βββ requirements.txt # Dependencies
βββ openkms-frontend/ # C# Blazor frontend
β βββ Components/ # Blazor components
β β βββ Auth/ # Authentication components
β β βββ Admin/ # Admin components
β β βββ Training/ # Training components
β β βββ Layout/ # Layout components
β βββ Services/ # Application services
β βββ Models/ # Data models
β βββ Properties/ # Build configuration
βββ scripts/ # Development scripts
βββ docs/ # Documentation
βββ nginx/ # Nginx configuration
βββ docker-compose.yml # Container orchestration
- Development Guide - Comprehensive development setup and workflow
- Deployment Guide - Production deployment instructions
- API Documentation - Backend API reference
- Component Documentation - Frontend component reference
- Admin Guide - System administration tasks
- Training Management - Creating and managing training programs
- User Management - User administration and permissions
The application uses environment variables for configuration. Copy .env.example to .env:
# Database
POSTGRES_PASSWORD=your_secure_password
DATABASE_URL=postgresql://openkms:your_secure_password@postgres:5432/openkms
# Redis
REDIS_URL=redis://redis:6379/0
# Security
SECRET_KEY=your-very-secure-secret-key-here
ALGORITHM=HS256
# Application
DEBUG=False # Set to False in production
LOG_LEVEL=INFO
ALLOWED_HOSTS=yourdomain.com
# URLs
FRONTEND_URL=https://yourdomain.com
BACKEND_URL=https://api.yourdomain.comFor production deployment, see DEPLOYMENT.md.
# Configure production environment
cp .env.example .env.production
# Edit .env.production with production values
# Deploy with production configuration
docker-compose -f docker-compose.yml -f docker-compose.prod.yml up -d- Docker Compose: Recommended for single-server deployments
- Kubernetes: For orchestrating multiple containers (see deployment guide)
- Cloud Platforms: AWS, Azure, GCP deployment guides available
- JWT Authentication: Stateless authentication with secure token handling
- Role-Based Access Control: Granular permissions for different user roles
- Password Security: Password hashing with bcrypt and complexity requirements
- Input Validation: Comprehensive validation using Pydantic schemas
- SQL Injection Prevention: SQLAlchemy ORM with parameterized queries
- HTTPS Enforcement: SSL/TLS encryption for all communications
- Secure password requirements (12+ characters, complexity enforced)
- Regular security updates for all dependencies
- Environment variable secrets management
- Request rate limiting
- CORS configuration
- Security headers implementation
- EMPLOYEE: Basic user access, can browse and register for trainings
- KNOWLEDGE_MANAGER: Can create and manage training programs
- ADMIN: Full system access, user management, and system configuration
| Feature | EMPLOYEE | KNOWLEDGE_MANAGER | ADMIN |
|---|---|---|---|
| View Trainings | β | β | β |
| Register for Trainings | β | β | β |
| Create Trainings | β | β | β |
| Manage Users | β | β | β |
| System Administration | β | β | β |
| View Reports | π* | β | β |
*Limited to own attendance data
- Health Checks: Automatic health monitoring for all services
- Performance Metrics: Request times, database queries, cache performance
- Error Tracking: Comprehensive error logging and alerting
- User Analytics: Training completion rates, user engagement metrics
- Prometheus: Metrics collection and alerting
- Grafana: Dashboard visualization
- ELK Stack: Log aggregation and analysis
- Sentry: Error tracking and reporting
- LDAP/Active Directory: Enterprise user authentication
- OAuth 2.0: Third-party authentication providers
- Webhooks: Event notifications to external systems
- REST API: Full API for external system integration
- User synchronization with HR systems
- Training content management systems
- Learning record stores (LRS)
- Email and notification systems
We welcome contributions! Please see our contributing guidelines:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'feat: add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Backend: Follow PEP 8, use black formatter, write comprehensive tests
- Frontend: Follow C# naming conventions, use XML documentation
- Testing: Maintain test coverage above 80% for all components
For bug reports and feature requests, please use the GitHub Issues page.
- Response Time: <200ms for API endpoints (95th percentile)
- Database Queries: <50ms for common operations with proper indexing
- Concurrent Users: 1000+ concurrent users with proper scaling
- Database Size: Optimized for 100,000+ user records
- Database indexing strategy
- Redis caching for frequently accessed data
- Async processing for non-blocking operations
- CDN support for static assets
- Database connection pooling
- Unit Tests: Component-level testing with mocking
- Integration Tests: API endpoint testing with database
- End-to-End Tests: Full user journey testing with Playwright
- Load Testing: Performance testing under peak load scenarios
- Backend: pytest with 80%+ coverage requirement
- Frontend: xUnit with bUnit for Blazor component testing
- API: Automated testing with pytest + httpx
- E2E: Playwright for critical user workflows
- Documentation: Check the comprehensive guides in the
docs/directory - Issues: GitHub Issues for bug reports
- Discussions: GitHub Discussions for questions
- Email: support@openkms.com for enterprise support
For common issues and solutions, see the troubleshooting sections in:
This project is licensed under the MIT License - see the LICENSE file for details.
- FastAPI Team: For the excellent web framework
- Microsoft: For the Blazor framework and .NET ecosystem
- Bootstrap Team: For the responsive UI framework
- PostgreSQL: For the robust database system
- Docker Team: For containerization technology
- Website: https://openkms.com
- Email: info@openkms.com
- Twitter: @openkms
- GitHub: https://github.com/your-org/openkms
Empowering organizations through streamlined knowledge management and training administration.
