This is an LMS (Learning Management System) portal project built with Next.js, UploadThing, and Mux. It allows users to upload and manage files such as images, videos, and documents with authentication and role-based access control.
- Upload course images, attachments, and chapter videos.
- Video streaming powered by Mux for high-quality playback.
- Role-based access control using Clerk authentication.
- File size and type restrictions for secure uploads.
- Middleware for custom authorization logic.
- API Routes:
app/api/uploadthing/route.ts
: Handles file upload routes.app/api/uploadthing/core.ts
: Defines file upload logic and middleware.
- Authentication: Uses Clerk for user authentication.
- Authorization: Custom logic to ensure only authorized users (e.g., teachers) can upload files.
- Video Streaming: Integrates Mux for video processing and playback.
- Node.js (v16 or later)
- npm, yarn, or pnpm
- Environment variables configured in a
.env
file (e.g., Clerk API keys, Mux API keys)
-
Clone the repository:
git clone <repository-url> cd <repository-folder>
-
Install dependencies:
npm install # or yarn install # or pnpm install
-
Start the development server:
npm run dev # or yarn dev # or pnpm dev
-
Open http://localhost:3000 in your browser to access the application.
You can deploy this project on platforms like Vercel for seamless hosting.
This project is licensed under the MIT License.