Live Classes with Recordings
A live-class platform where learners join their tutors from the browser on any device: morning, evening, special and questions classes with chat, reactions and recordings to watch again.
Live Classes grew out of QBank. I took the live-class side of that product and turned it into a product of its own, with its own subscriptions, database and deployment. It shares the codebase's foundations: the ASP.NET Core API, the Angular application, real-time classes and payments.
It is live at class.passrnnclex.com, running on the same server as QBank without the two getting in each other's way.
Key Features
1. A Classroom in the Browser
Audio, video and screen sharing go through a self-hosted LiveKit SFU, so a class can hold far more people than a browser-to-browser call. SignalR carries presence, chat, raised questions, reactions and class state.
Recordings are made on the server by LiveKit Egress and saved after the class, for subscribed learners to watch again.
2. Class Types and Schedules
Tutors run morning, evening, special and questions classes on recurring schedules that keep the same local time across daylight-saving changes. Marathon classes are open to anyone with a morning, evening or special subscription.
Open discussion classes can be joined by guests through a link, without an account. A guest token only works for that one class.
3. Subscriptions per Class Type
Each class type is its own plan. Learners pay with M-Pesa (Safaricom Daraja STK push) or by card through Paystack. Prices are set in US dollars and converted to Kenyan shillings.
Plans and payment groups are edited in the app, and staff requests such as granting a subscription go through an approval step.
4. Calendar, Notifications and Support
A shared calendar shows upcoming classes and events, with reminders before a class starts. Editable email templates send welcome, activation and sign-in emails from accounts managed in the app, and a live support chat answers learners' questions.
5. Administration
Roles have fine-grained permissions, user groups organise learners, and each account may sign in on one computer and one phone browser to stop sharing. Staff can "view as" a learner, follow an activity log, and switch whole sections of the menu off for everyone.
Architecture
- API: ASP.NET Core 8 with Entity Framework Core, JWT authentication, ASP.NET Identity and SignalR hubs for classrooms, notifications and support.
- Web: an Angular 21 single-page application served by Nginx, which also proxies
/apito the API container. - Database: PostgreSQL, kept separate from QBank's data. Migrations run on every deploy.
- Media: a self-hosted LiveKit SFU, with TURN for restrictive networks.
- Hosting: Docker Compose on a Linux VPS. Nothing is exposed directly to the internet; the public reaches the site through a Cloudflare Tunnel.
Two Products on One Server
Live Classes was deployed next to QBank on the same server, so it was set up to share nothing that could collide: its own configuration and secrets, its own containers and its own database, with no downtime for the site already running there. A new hostname on the existing Cloudflare Tunnel routes class.passrnnclex.com to it.
The one shared piece is the media server. Recording workers take their jobs from a shared queue, so a second worker could pick up the other site's recordings and save them in the wrong place. Recording therefore runs on one site only until the two get separate queues.
CI/CD Pipeline
The repository is on GitHub, and the pipeline is the same one QBank uses. Every pull request builds the API and runs the Angular unit tests. A push to main builds the API and web images, pushes them to the GitHub Container Registry tagged with the commit, and deploys them to the VPS over SSH with a key that is used only for this repository.
It runs on GitHub's free plan. Private packages get 500 MB of storage there, so the registry keeps the newest three versions of each image: enough to roll back two deploys by re-running an older workflow.
Technologies Used
- C# and ASP.NET Core 8
- Entity Framework Core
- ASP.NET Identity and JWT
- SignalR
- Angular 21
- PostgreSQL
- LiveKit (WebRTC SFU) and LiveKit Egress
- Paystack and M-Pesa Daraja APIs
- Docker and Docker Compose
- Nginx
- GitHub Actions and GitHub Container Registry
- Cloudflare Tunnel
- Debian Linux
What This Project Demonstrates
Live Classes shows how to turn one part of an existing product into a product of its own. That meant cutting features cleanly out of a shared codebase and starting a fresh database schema, with its own plans and payments.
It also shows careful operations on shared infrastructure: a second production app added to a live server, kept fully separate from the first, with no downtime for the site already running there.