A platform where teachers can create and manage lessons for their groups in an intuitive and enjoyable way. The main focus is on easy deployment and initial scalability for smaller target audiences.
- Laravel - chosen for its simplicity, convenience, and ease of application development
- PostgreSQL - as the database for its reliability and performance
- AWS S3 - for storing uploaded images, ensuring availability without infrastructure concerns
- Pusher - for real-time notifications to ensure application scalability
- React with TypeScript
- shadcn/ui components
- TailwindCSS for styling
- Inertia.js for server-side rendering capabilities
The application follows Domain-Driven Design (DDD) principles with a ports and adapters architecture to ensure extensibility and universality. While the implementation might not strictly follow all theoretical guidelines, it maintains the core benefits of the architecture.
Key architectural decisions:
- Stateless Laravel application for horizontal scalability
- PostgreSQL as the primary database
- S3 for image storage
- Pusher for scalable notifications
- JWT-based authentication
- OAuth2 support for GitHub and Google login
- Administrators can:
- Create groups
- Add users to groups
- Create sections within groups
- Create lessons within sections
- Full Markdown editor support
- Text formatting capabilities
- Image insertion
- Syntax highlighting for code snippets
- Scheduled publishing (not implemented yet)
- Group-specific access control (not implemented yet)
- Access to authorized lessons (not implemented yet)
- Real-time notifications for new lessons (not implemented yet)
- PHP 8.3 or higher
- Node.js
- pnpm
- Clone the repository
git clone https://github.com/SekulDev/learning_platform.git
cd learning_platform
- Install PHP dependencies
composer install
- Install frontend dependencies
pnpm install
- Configure environment
cp .env.example .env
php artisan key:generate
- Configure your
.env
file with:
- Database credentials
- S3 credentials
- Pusher credentials
- OAuth credentials
- Run migrations
php artisan migrate
- Start the development servers
php artisan serve
pnpm dev
To run PHPUnit tests:
php artisan test
Configure environment and put your variables into .env
cp .env.example .env
php artisan key:generate
To deploy using Docker:
docker-compose --env-file .env up -d --build
Run Migrations in docker and then restart containers
docker-compose exec -w /var/www/html app1 php artisan migrate
This project was developed as part of a challenge within several dozen hours by a single developer. Due to the time constraints and scope, some decisions were made to optimize development speed:
- Direct commits to main branch (as a solo developer)
- Focus on core functionality over comprehensive testing
- Not finished all features
- Missing integration and E2E tests (only unit tests present)
- Insufficient abstraction level in some cases
- Lack of comprehensive documentation
The project served as an excellent learning experience with DDD and ports and adapters architecture, providing valuable insights into architectural patterns and their practical implementation.
I'm open to suggestions and improvements! Feel free to:
- Submit issues
- Propose improvements
- Share feedback on the architecture
The goal is to learn and improve, so all constructive input is welcome.