This repository follows a Docker-first approach.
The application must be fully operational through Docker.
Developers should not be required to install PHP, Composer, Node.js or PostgreSQL directly on their host machine.
All project operations must be executable through Docker containers.
Always use Docker.
Never ask developers to run:
php
composer
symfony
npm
yarn
pnpm
directly on the host machine.
Use Makefile commands instead.
Expected containers:
app
postgres
mailcatcher
gotenberg
Optional:
node
if separated from the PHP container.
The application container is responsible for:
The container should be the primary development environment.
Mandatory version:
PHP 8.4
Container type:
PHP-FPM
Database:
PostgreSQL
Use the latest stable version available.
Port mapping:
127.0.0.1:5432:5432
Requirements:
Mailcatcher is mandatory.
Purpose:
No external SMTP service should be required.
Gotenberg is mandatory.
Purpose:
Expected service name:
gotenberg
The application should communicate with Gotenberg through a dedicated service.
Example:
PdfGeneratorService
The local developer user is:
1000:1000
Dockerfiles must support:
ARG UID=1000
ARG GID=1000
Purpose:
The following directories must remain writable:
var/
var/cache/
var/log/
vendor/
node_modules/
Generated files must remain editable by the local user.
Expected persistent volumes:
postgres_data
Optional:
composer_cache
npm_cache
The project should use:
compose.yaml
Optional:
compose.override.yaml
Avoid maintaining multiple Compose configurations without justification.
Sensitive values must never be hardcoded.
Use:
.env
.env.local
.env.test
Provide:
.env.example
for onboarding.
The Makefile is the primary entry point.
All recurring commands must be available through Make targets.
make build
make up
make down
make restart
make logs
make shell
Purpose:
Open a shell in the application container.
make composer-install
make composer-update
make composer-require
Composer must run inside Docker.
Bad:
composer install
Good:
make composer-install
make npm-install
make npm-build
make npm-dev
make db-create
make db-migrate
make db-diff
make fixtures
make test
make phpstan
make lint
make lint-php
make lint-twig
XDebug must be enabled.
Purpose:
The repository must provide:
docs/vscode-xdebug.md
This file must contain:
Default port:
9003
Container:
/var/www/html
Host:
${workspaceFolder}
Symfony commands must run inside Docker.
Bad:
php bin/console cache:clear
Good:
make console CMD="cache:clear"
NPM commands must run inside Docker.
Bad:
npm install
Good:
make npm-install
All schema changes must use Doctrine migrations.
Never modify the database manually.
Expected workflow:
make db-diff
make db-migrate
Fixtures should provide a working development environment.
Minimum fixtures:
Admin User
Regular User
Default password:
rt0zclln
Fixtures must be executable through:
make fixtures
A dedicated test environment must exist.
Expected file:
.env.test
Tests must not use the development database.
All commands available locally through Makefile must be executable in CI.
CI should be able to execute:
make test
make phpstan
make lint
without modifications.
Before validating infrastructure changes:
Infrastructure must remain reproducible across machines.
How can I help you explore Laravel packages today?