Problem
It may happen that we forget to generate a migration. That would result into a difference between the entities and the database. This shouldn't happen as it could generate weird issues difficult to debug.
Also, it can happen that developers add a file that shouldn't be, like a SQL dump file :)
Solution
Add two checks on the CI:
- the first must run the
console make:migration command and fail if a file is generated.
- the second must check for the presence of any
*.sql, *dump*, or .env* files and fail if it detects one which isn't in a safe list (such as /.env.example for instance)
Related issues
Problem
It may happen that we forget to generate a migration. That would result into a difference between the entities and the database. This shouldn't happen as it could generate weird issues difficult to debug.
Also, it can happen that developers add a file that shouldn't be, like a SQL dump file :)
Solution
Add two checks on the CI:
console make:migrationcommand and fail if a file is generated.*.sql,*dump*, or.env*files and fail if it detects one which isn't in a safe list (such as/.env.examplefor instance)Related issues