A feature-rich, self-hosted cloud storage solution with advanced security, user management, and comprehensive admin controls.
Features β’ Screenshots β’ Installation β’ Documentation β’ License
Platinum Drive is an open-source cloud storage platform built with modern technologies, offering enterprise-level features for individuals and organizations. With a beautiful RTL interface, robust security features, and comprehensive admin controls, it's perfect for teams looking for a self-hosted storage solution.
β οΈ Language Notice: This project is currently available only in Arabic language with full RTL (Right-to-Left) support and Hijri calendar integration.β οΈ For Demo: Email: user@platinum-app.com Password: 123456, I have Disabled some of the Settings in the user side, for the ADmin Side and FULLY FUNCATIONAL Version Contact me to Send the Deatils to you.
View Full Screenshots Gallery β
|
|
|
|
- β RTL Support for Arabic language
- β Dark Mode with system preference detection
- β Responsive Design for all devices
- β Live Arabic Clock with Hijri calendar
- β Toast Notifications for user feedback
- β Tab Navigation with active indicators
|
|
|
- Node.js 20.x or higher
- PostgreSQL 14.x or higher
- npm or yarn package manager
# 1. Clone the repository
git clone https://github.com/youssef509/Platinum-Drive.git
cd Platinum-Drive
# 2. Install dependencies
npm install
# 3. Set up environment variables
cp .env.example .env
# Edit .env with your configuration
# 4. Set up the database
npx prisma migrate dev
npx prisma db seed
# 5. Run the development server
npm run devVisit http://localhost:3000 π
After seeding the database, you can log in with:
- Email: (check your seed file)
- Password: (check your seed file)
Create a .env file in the root directory:
# Database
DATABASE_URL="postgresql://user:password@localhost:5432/platinum_drive"
# NextAuth
NEXTAUTH_SECRET="your-secret-key-here"
NEXTAUTH_URL="http://localhost:3000"
AUTH_TRUST_HOST="true"
# Email (Optional - for verification & 2FA)
SMTP_HOST="smtp.gmail.com"
SMTP_PORT="587"
SMTP_USER="your-email@gmail.com"
SMTP_PASSWORD="your-app-password"
SMTP_FROM="noreply@platinumdrive.com"After installation, navigate to Admin Panel β System Settings to configure:
- General: Site name, maintenance mode, language
- Security: 2FA enforcement, password policies, login limits
- Email: SMTP server configuration
- Upload: File size limits, virus scanning
- Storage: User quotas, auto-cleanup policies
- Appearance: Theme, logo, branding
- Notifications: Alert preferences
- Advanced: System-level configurations
Core Tables:
Users- User accounts with roles and quotasFiles- Uploaded files with metadataFolders- Folder hierarchyShares- Secure file sharingSystemSettings- Application configFileTypePolicy- File validation rulesNotifications- User notificationsLoginHistory- Login trackingPasswordHistory- Password changesVerificationCode- Email codesTwoFactorCode- 2FA OTP codes
See prisma/schema.prisma for the complete schema.
Click to expand API documentation
POST /api/auth/register - Register new user
POST /api/auth/verify-credentials - Verify login credentials
POST /api/auth/verify - Verify email code
POST /api/auth/request-2fa - Request 2FA code
POST /api/auth/verify-2fa - Verify 2FA code
POST /api/files/upload - Upload files
GET /api/files - List user files
GET /api/files/[id]/download - Download file
DELETE /api/files/[id] - Delete file
POST /api/files/[id]/favorite - Toggle favorite
POST /api/share - Create share link
GET /api/share/public/[token] - Access shared file
GET /api/share/download/[token] - Download shared file
GET /api/admin/users - List all users
PUT /api/admin/users/[id]/status - Update user status
PUT /api/admin/users/[id]/quota - Update storage quota
GET /api/admin/settings - Get system settings
PUT /api/admin/settings/[key] - Update setting
GET /api/admin/file-types - List file type policies
POST /api/admin/file-types - Create file type policy
The system includes 16 default file types out of the box:
| Category | Types | Max Size |
|---|---|---|
| Images | jpg, png, gif, webp | 10 MB |
| Documents | pdf, doc, docx, xls, xlsx, txt | 50 MB |
| Audio | mp3, wav | 50-100 MB |
| Video | mp4, mpeg | 500 MB |
| Archives | zip, rar | 500 MB |
Admins can customize these limits or add new types via the admin panel.
- β Strong password requirements (8+ chars, mixed case, numbers, symbols)
- β Account lockout after failed login attempts
- β Session management with HTTP-only cookies
- β Role-based access control (RBAC)
- β Admin-controlled global enforcement
- β Time-based OTP codes (10-minute expiry)
- β Email delivery with resend functionality
- β Visual countdown timer
- β 6-digit verification codes
- β 15-minute code expiry
- β Required for account activation
- β Password history (prevents reuse)
- β Configurable expiry policies
- β Bcrypt hashing algorithm
- β Complexity enforcement
- β File type validation
- β Size limit enforcement
- β Virus scanning capability (configurable)
- β Access control per file
- β Secure share tokens
# Build the image
docker build -t platinum-drive .
# Run the container
docker run -p 3000:3000 \
-e DATABASE_URL="your-db-url" \
-e NEXTAUTH_SECRET="your-secret" \
platinum-drive# Set your project
gcloud config set project YOUR_PROJECT_ID
# Enable required APIs
gcloud services enable cloudbuild.googleapis.com run.googleapis.com
# Build and push the image
gcloud builds submit --tag gcr.io/YOUR_PROJECT_ID/platinum-drive
# Deploy to Cloud Run
gcloud run deploy platinum-drive \
--image gcr.io/YOUR_PROJECT_ID/platinum-drive \
--platform managed \
--region europe-west1 \
--allow-unauthenticated \
--port 8080 \
--set-env-vars DATABASE_URL="your-db-url",NEXTAUTH_SECRET="your-secret"DATABASE_URL=postgresql://user:pass@host:5432/dbname
NEXTAUTH_SECRET=your-production-secret-min-32-chars
NEXTAUTH_URL=https://your-domain.com
AUTH_TRUST_HOST=true
NODE_ENV=production
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your-email@gmail.com
SMTP_PASSWORD=your-app-password
SMTP_FROM=noreply@your-domain.com# Development
npm run dev # Start development server
npm run build # Build for production
npm start # Start production server
# Database
npx prisma migrate dev # Run migrations (dev)
npx prisma migrate deploy # Run migrations (prod)
npx prisma generate # Generate Prisma Client
npx prisma studio # Open Prisma Studio GUI
npx prisma db seed # Seed database with initial data
# Type Checking & Linting
npm run type-check # Run TypeScript compiler check
npm run lint # Run ESLintplatinum-drive/
βββ prisma/
β βββ schema.prisma # Database schema
β βββ seed.ts # Database seeding script
β βββ migrations/ # Database migrations
βββ public/
β βββ uploads/ # User uploaded files
β βββ avatars/ # User avatars
β βββ files/ # Uploaded files
βββ src/
β βββ app/ # Next.js App Router
β β βββ (auth)/ # Auth pages (login, register, verify)
β β βββ admin/ # Admin panel pages
β β βββ api/ # API routes
β β βββ files/ # File management pages
β β βββ profile/ # User profile pages
β β βββ settings/ # User settings pages
β βββ components/ # React components
β β βββ ui/ # Shadcn UI components
β β βββ shared/ # Shared components
β β βββ layout/ # Layout components
β βββ hooks/ # Custom React hooks
β βββ lib/ # Utility libraries
β β βββ auth/ # Authentication logic
β β βββ db/ # Database utilities
β β βββ security/ # Security utilities
β β βββ utils/ # General utilities
β βββ types/ # TypeScript type definitions
βββ Dockerfile # Docker configuration
βββ docker-compose.yml # Docker Compose setup
βββ .env.example # Environment variables template
βββ package.json # Dependencies and scripts
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
If you discover a bug, please create an issue on GitHub with:
- Description of the bug
- Steps to reproduce
- Expected behavior
- Screenshots (if applicable)
- Your environment (OS, Node version, etc.)
This project is licensed under the MIT License - see the LICENSE file for details.
MIT License
Copyright (c) 2025 Youssef Ahmed
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
Youssef Ahmed
- GitHub: @youssef509
- Email: youssef201.dev@gmail.com
- LinkedIn: Connect with me
Built with amazing open-source technologies:
- Next.js - The React Framework for Production
- Prisma - Next-generation ORM
- NextAuth.js - Authentication for Next.js
- Tailwind CSS - Utility-first CSS framework
- Shadcn/ui - Re-usable component library
- Lucide Icons - Beautiful & consistent icons
- PostgreSQL - Advanced open-source database
If you find this project useful, please consider giving it a star on GitHub! It helps others discover the project and motivates continued development.
Made with β€οΈ by Youssef Ahmed
Platinum Drive - Your files, secure and accessible βοΈ


