π Built with dragon-like precision and wisdom π
Bergaman Portal is a personal portfolio, blog, and recommendation platform built with Next.js 15, React, and MongoDB. The application features a responsive design, admin dashboard, and various interactive components.
- Portfolio Showcase: Display your projects with detailed information
- Blog System: Write and publish articles with Markdown support
- Recommendation System: Share your favorite games, books, and movies
- Admin Dashboard: Manage all content through an intuitive admin interface
- Comment System: Allow visitors to comment on blog posts
- Contact Form: Let visitors reach out to you with full reply system
- Reply System: Bidirectional messaging between admin and users
- Newsletter: Collect subscriber emails and send campaigns
- User Authentication: Secure admin access with JWT
- Admin Logs: Track all admin activities with detailed logging
- Responsive Design: Works on all devices from mobile to desktop
- Frontend: Next.js 15, React, TailwindCSS
- Backend: Next.js API Routes
- Database: MongoDB with Mongoose ODM
- Authentication: JWT, HTTP-only cookies
- Deployment: Vercel
- Media Storage: Local storage with option for cloud storage
- Node.js 18.17 or later
- MongoDB database
- npm or yarn
-
Clone the repository:
git clone https://github.com/yourusername/bergaman-portal.git cd bergaman-portal -
Install dependencies:
npm install # or yarn install -
Create a
.envfile in the root directory with the following variables:MONGODB_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret ADMIN_USERNAME=your_admin_username ADMIN_PASSWORD=your_admin_password_hash NEXTAUTH_URL=http://localhost:3000 -
Run the development server:
npm run dev # or yarn dev -
Open http://localhost:3000 in your browser
Access the admin dashboard at http://localhost:3000/admin using the credentials you set in the .env file.
The admin dashboard allows you to:
- Create, edit, and delete blog posts
- Manage portfolio projects
- Add and edit recommendations
- Moderate comments
- View contact messages
- Manage newsletter subscribers and campaigns
- View system logs and admin activities
- Update site settings
- JWT-based authentication with HTTP-only cookies
- CSRF protection
- Rate limiting for login attempts
- Session timeout
- Admin activity logging
- IP tracking for suspicious activities
You can customize the site by:
- Modifying the TailwindCSS configuration in
tailwind.config.js - Updating site metadata in
src/app/layout.js - Changing colors and styles in
src/app/globals.css - Adding new components in
src/app/components
This project is licensed under the MIT License - see the LICENSE file for details.
- Next.js team for the amazing framework
- TailwindCSS for the utility-first CSS framework
- MongoDB for the flexible document database
- All open-source contributors whose libraries made this project possible
- π Current Version (v2.5.13): bergaman.dev
- π°οΈ Legacy Version (v1.0.0): bergaman-v1.vercel.app
- Mystical Background Effects: Floating orbs, energy streams, and dragon breath animations
- Dragon Scale Patterns: Custom SVG patterns for authentic dragon aesthetics
- Golden Color Palette: Inspired by dragon gold with deep forest backgrounds
- Responsive Design: Optimized for all devices with smooth animations
- Bergasoft Portal: Professional admin interface with dragon-themed effects
- Real-time Dashboard: Live statistics, recent activity, and system monitoring
- Content Management: Create, edit, and manage blog posts with rich editor
- User Management: Admin authentication and role-based access control
- Analytics Tracking: View counts, engagement metrics, and performance data
- Newsletter Management: Complete subscriber and campaign management system
- Enhanced UI Components: Reusable components with multiple design variants
- Consistent Layout: PageHeader components across all admin pages
- MongoDB Integration: Full database-driven content management
- SEO Optimization: Dynamic meta tags, structured data, and sitemap generation
- Comment System: Advanced commenting with IP tracking and moderation
- Categories & Tags: Organized content with filtering and search capabilities
- Subscriber Management: Complete newsletter signup and management system
- Campaign Creation: Rich markdown-based email campaigns with templates
- Audience Targeting: Segment subscribers by preferences and activity
- Real-time Statistics: Track subscriber counts, open rates, and engagement
- Unsubscribe Management: One-click unsubscribe with preference center
- Email Templates: Professional dragon-themed email designs
- Batch Sending: Efficient email delivery with rate limiting
- GitHub Actions: Automated version management and releases
- Semantic Versioning: Automatic version bumping based on commit messages
- Environment Management: Dynamic version tracking and deployment
- Performance Monitoring: Core Web Vitals and analytics integration
- Dependabot Integration: Automated security updates and dependency management
- Modal System: 15+ design variants including modern, elegant, glass, and more
- Button Components: Consistent button styling with multiple variants
- Select Components: Versatile dropdown selects with multiple variants, sizes, and icon support
- Loading Components: Customizable loading spinners with overlay and full-screen options
- Tabs Components: Interactive tab navigation with multiple styles and animations
- Tooltip Components: Rich tooltip system with positioning and interactive content
- PageHeader: Flexible page headers with actions, stats, and filters
- Form Elements: Styled inputs, selects, and form controls
- Card Components: Versatile card layouts for content display
- Component Showcase: Interactive component library for testing and demonstration
- Framework: Next.js 15+ (App Router)
- Database: MongoDB Atlas with Mongoose ODM
- Styling: Tailwind CSS with custom dragon themes
- Authentication: Custom admin authentication system
- Deployment: Vercel with GitHub Actions CI/CD
- Icons: FontAwesome 6.5.1
- Analytics: Vercel Analytics
- Email: Nodemailer for contact forms and newsletters
- Fonts: Inter (Google) + Geist (Local)
- Image Optimization: Next.js Image component
- Markdown: Marked for rich content rendering
- Security: bcryptjs for password hashing
- Node.js 18+
- MongoDB Atlas account
- Git
- Gmail account (for email functionality)
# Clone the repository
git clone https://github.com/bergaman9/bergaman-dev.git
cd bergaman-dev
# Install dependencies
npm install
# Set up environment variables
cp .env.example .env.local
# Edit .env.local with your configuration
# Start development server
npm run dev# .env.local
MONGODB_URI=mongodb+srv://your-username:your-password@your-cluster.mongodb.net/your-database
NEXTAUTH_SECRET=your-secret-key
NEXT_PUBLIC_SITE_URL=http://localhost:3000
NEXT_PUBLIC_APP_VERSION=2.1.1
EMAIL_USER=your-email@gmail.com
EMAIL_PASS=your-app-password
VERCEL_TOKEN=your-vercel-token (optional)
VERCEL_ORG_ID=your-org-id (optional)
VERCEL_PROJECT_ID=your-project-id (optional)
β οΈ Security Note: The.env.examplefile uses placeholder values to prevent GitHub's secret scanning alerts. Always replace these with your actual credentials in your local.env.localfile.
bergaman-dev/
βββ .github/workflows/ # GitHub Actions & Dependabot
βββ public/images/ # Static assets
βββ src/
β βββ app/
β β βββ (admin)/ # Admin panel routes
β β βββ api/ # API endpoints
β β βββ blog/ # Blog pages
β β βββ newsletter/ # Newsletter pages
β β βββ components/ # Reusable components
β β βββ ...
β βββ lib/ # Utilities and constants
β βββ models/ # MongoDB schemas
β βββ data/ # Static data files
βββ ...
- Navigate to
/admin - Enter your admin credentials (configured in environment variables)
- Access the dragon-themed dashboard
- Create Posts: Rich editor with live preview
- Manage Comments: Approve, reject, and moderate
- View Analytics: Track engagement and performance
- System Monitoring: Real-time server status
- Subscriber Overview: View all subscribers with status tracking
- Campaign Creation: Create rich markdown-based email campaigns
- Audience Targeting: Send to active subscribers or specific segments
- Performance Tracking: Monitor open rates and engagement metrics
- Automatic Versioning: Based on commit message patterns
- Release Generation: Automated GitHub releases
- Environment Sync: Version updates across all environments
- Primary:
#e8c547(Dragon Gold) - Background:
#0e1b12(Deep Forest) - Secondary:
#2e3d29(Forest Green) - Accent:
#3e503e(Sage Green)
- Floating Orbs: Mystical particles with shadows
- Energy Streams: Vertical gradient animations
- Dragon Breath: Rotating conic gradients
- Scale Patterns: Custom SVG textures
GET /api/admin/posts- List all postsPOST /api/admin/posts- Create new postPUT /api/admin/posts/[id]- Update postDELETE /api/admin/posts/[id]- Delete post
GET /api/admin/comments- List commentsPUT /api/admin/comments/[id]- Moderate comment
GET /api/contacts/[id]- Get contact details (public)POST /api/contacts/reply- Send reply to conversation (public)POST /api/admin/contacts/[id]/reply- Admin reply to contact
POST /api/newsletter/subscribe- Subscribe to newsletterPOST /api/newsletter/unsubscribe- Unsubscribe from newsletterGET /api/newsletter/stats- Get subscriber statisticsGET /api/admin/newsletter/subscribers- List all subscribersGET /api/admin/newsletter/campaigns- List all campaignsPOST /api/admin/newsletter/campaigns- Create new campaignPOST /api/admin/newsletter/campaigns/[id]/send- Send campaign
GET /api/admin/analytics- Get statisticsPUT /api/posts/[id]/view- Track page views
- Connect GitHub repository to Vercel
- Set environment variables in dashboard
- Deploy automatically on push to main
- Version Bumping: Automatic semantic versioning
- Release Creation: Generated changelogs and tags
- Build Validation: Tests and quality checks
- Dependency Updates: Automated security patches
MONGODB_URI - MongoDB Atlas connection string
NEXTAUTH_SECRET - Authentication secret key
EMAIL_USER - Gmail address for email functionality
EMAIL_PASS - Gmail app password
VERCEL_TOKEN - Vercel deployment token
VERCEL_ORG_ID - Vercel organization ID
VERCEL_PROJECT_ID - Vercel project ID
- Admin Authentication: Secure login system with bcrypt
- Input Validation: XSS and injection protection
- Rate Limiting: API endpoint protection
- Environment Security: Sensitive data encryption
- Newsletter Security: Email validation and unsubscribe protection
- Core Web Vitals: Optimized for Google metrics
- Image Optimization: Next.js Image with lazy loading
- Code Splitting: Route-based bundle optimization
- Caching Strategy: Efficient data fetching
- Email Delivery: Batch processing with rate limiting
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'feat: add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open Pull Request
feat:- New features (minor version bump)fix:- Bug fixes (patch version bump)BREAKING CHANGE:- Major changes (major version bump)
This project is licensed under the MIT License - see the LICENSE file for details.
Γmer (Bergaman)
- π Website: bergaman.dev
- π GitHub: @bergaman9
- π§ Email: contact@bergaman.dev
- Next.js team for the incredible framework
- MongoDB for robust database solutions
- Vercel for seamless deployment
- FontAwesome for comprehensive icons
- Tailwind CSS for utility-first styling
- π¬ Contact Reply System: Full bidirectional messaging between admin and users
- π Real-time Notifications: Admin notifications for user replies
- π§ Email Integration: Automated email notifications for replies
- π¨ Enhanced UI Components: Improved modal system with backdrop click
- π Real System Stats: Live memory usage and session tracking
- π’ Version Management: Removed 'v' prefix from all version displays
- π― Admin Improvements: Better conversation tracking and status management
- π Security Enhancements: Rate limiting for public reply endpoints
- π οΈ Fixed initialization errors in Next.js server components
- π§ Improved version handling in dynamic environments
- π Updated to Next.js 15.3.3 with Turbopack support
- π¨ Enhanced middleware with force-dynamic rendering
- π Improved recommendation system with new data structure
- π Fixed security issues in middleware authentication
- β‘ Performance optimizations for faster loading times
- π§ Complete newsletter system with subscriber management
- π¨ Email campaign creation and sending functionality
- π Real-time newsletter statistics and analytics
- π§ Enhanced GitHub Actions with Dependabot integration
- π Fixed hydration errors and build issues
- π¨ Improved admin panel with green dragon theme
- π Enhanced security with better error handling
- ποΈ Full MongoDB integration
- π οΈ Advanced admin panel with dragon effects
- βοΈ Real-time content management
- π Analytics and monitoring
- π Automated version management
- π¨ Static portfolio website
- π Basic blog functionality
- π― SEO optimization
- π± Responsive design
- π Repository: github.com/bergaman9/bergaman-dev
- π·οΈ Releases: github.com/bergaman9/bergaman-dev/releases
- π Documentation: bergaman.dev/docs
- π Issues: github.com/bergaman9/bergaman-dev/issues
- π§ Newsletter: bergaman.dev/newsletter