Fix database container creation

This commit is contained in:
Frank
2026-03-10 22:04:23 +01:00
parent eb3d36c99f
commit 539a243353
3 changed files with 17 additions and 4 deletions
Executable → Regular
+10 -2
View File
@@ -104,9 +104,17 @@ fi
# Prepare DB
echo "Creating database if it doesn't exist..."
pexec php bin/console doctrine:database:create --if-not-exists
if ! pexec php bin/console doctrine:database:create --if-not-exists; then
echo "Error: Database creation failed. Check Docker logs for details." >&2
dc logs database
exit 1
fi
echo "Running migrations..."
pexec php bin/console doctrine:migrations:migrate -n
if ! pexec php bin/console doctrine:migrations:migrate -n; then
echo "Error: Migrations failed." >&2
exit 1
fi
# Import JS deps (Importmap/Asset Mapper)
if [ -f "$ROOT_DIR/importmap.php" ]; then