A production-ready MVC web application framework targeting PHP 8.2.
- PHP 8.2+
- Composer
- Docker & Docker Compose (for local development)
The project ships with a complete Docker Compose environment.
- Clone the repository setting up this framework.
- Initialize
.envfile:cp .env.example .env
- Boot up the environment:
make up
- Access the application on http://localhost:8080.
- Install dependencies inside container:
docker-compose exec app composer install
This framework strictly follows the MVC pattern, enforcing separation of concerns:
- Models: Data representation and mapped entities.
- Repositories: Data access and persistance (PDO).
- Services: Business logic and orchestrations.
- Controllers: Validates HTTP input, delegates to Services, and returns HTTP responses.
- Views: PHP rendering logic, explicitly isolated.
The application utilizes a custom Dependency Injection (DI) Container for object lifecycle management.
Use the Makefile to run operational tasks:
make up: Start containers.make down: Stop containers.make bash: Access the PHP shell.make test: Run PHPUnit with coverage.make lint: Run PHP_CodeSniffer for PSR-12 compliance.make analyze: Run PHPStan static analysis (Level 8).make migrate: Execute pending migrations.