Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions bin/migrations.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
use Doctrine\Migrations\Tools\Console\Command;
use Symfony\Component\Console\Application;

$env = getenv('APP_ENV') ?: '';
$env = getenv('APP_ENV') ?? 'global';

$dbParams = (require realpath(__DIR__) . sprintf('/../config/autoload/database.%s.php', $env))['database'];
$dbParams['driver'] = 'pdo_' . $dbParams['driver'];
Expand All @@ -25,10 +25,10 @@

$configuration->setCustomTemplate(__DIR__ . '/../config/migrations.template.tpl');

$configuration->addMigrationsDirectory('Migrations', $config['migrations_paths']['Migrations']);
if (array_key_exists('TestDataMigrations', $config['migrations_paths'])) {
$configuration->addMigrationsDirectory('TestDataMigrations', $config['migrations_paths']['TestDataMigrations']);
foreach ($config['migrations_paths'] as $key => $path) {
$configuration->addMigrationsDirectory($key, $path);
}

$configuration->setAllOrNothing($config['all_or_nothing']);
$configuration->setCheckDatabasePlatform($config['check_database_platform']);
$configuration->setTransactional($config['transactional']);
Expand Down
33 changes: 6 additions & 27 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,26 +41,8 @@
"ext-json": "*",
"ext-openssl": "*",
"ext-pdo": "*",
"envms/fluentpdo": "^2.2",
"firebase/php-jwt": "^6.0",
"laminas/laminas-config-aggregator": "^1.6",
"laminas/laminas-diactoros": "^3.8.0",
"laminas/laminas-inputfilter": "^2.30",
"laminas/laminas-servicemanager": "^3.4",
"laminas/laminas-stdlib": "^3.6",
"laminas/laminas-validator": "^2.64",
"laminas/laminas-component-installer": "^2.6 || ^3.0",
"laminas/laminas-development-mode": "^3.3.0",
"mezzio/mezzio-tooling": "^2.12",
"mezzio/mezzio": "^3",
"mezzio/mezzio-cors": "^1.13",
"mezzio/mezzio-fastroute": "^3.0.3",
"mezzio/mezzio-helpers": "^5.7",
"monolog/monolog": "^3.9.0",
"ramsey/uuid": "^4.7",
"symfony/mailer": "^6.4",
"zircote/swagger-php": "^6",
"jetbrains/phpstorm-attributes": "^1.0"
"exdrals/core": "^0.1.0",
"exdrals/identity": "^0.1.0"
},
"require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "^1.2",
Expand All @@ -82,13 +64,10 @@
},
"autoload": {
"psr-4": {
"ownHackathon\\" : "src/App/",
"ownHackathon\\Shared\\" : "src/App/Shared/src/",
"ownHackathon\\Account\\" : "src/App/Account/",
"ownHackathon\\Workspace\\" : "src/App/Workspace/src/",
"Exdrals\\Shared\\": "src/Shared/src",
"Exdrals\\Identity\\" : "src/App/Account/Identity/src/",
"Exdrals\\Mailing\\" : "src/App/Mailing/src/"
"ownHackathon\\": "src/App/",
"ownHackathon\\Shared\\": "src/App/Shared/src/",
"ownHackathon\\Account\\": "src/App/Account/",
"ownHackathon\\Workspace\\": "src/App/Workspace/src/"
}
},
"autoload-dev": {
Expand Down
173 changes: 161 additions & 12 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion config/autoload/migrations.action.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],

'migrations_paths' => [
'Migrations' => __DIR__ . '/../../database/migrations',
'Exdrals\\Identity\\Migrations' => 'vendor/exdrals/identity/database/migrations',
'ownHackathon\\Migrations' => 'database/migrations',
],

'all_or_nothing' => true,
Expand Down
3 changes: 2 additions & 1 deletion config/autoload/migrations.develope.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],

'migrations_paths' => [
'Migrations' => __DIR__ . '/../../database/migrations',
'Exdrals\\Identity\\Migrations' => 'vendor/exdrals/identity/database/migrations',
'ownHackathon\\Migrations' => 'database/migrations',
],

'all_or_nothing' => true,
Expand Down
3 changes: 2 additions & 1 deletion config/autoload/migrations.global.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],

'migrations_paths' => [
'Migrations' => __DIR__ . '/../../database/migrations',
'Exdrals\\Identity\\Migrations' => 'vendor/exdrals/identity/database/migrations',
'ownHackathon\\Migrations' => 'database/migrations',
],

'all_or_nothing' => true,
Expand Down
3 changes: 2 additions & 1 deletion config/autoload/migrations.testing.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],

'migrations_paths' => [
'Migrations' => __DIR__ . '/../../database/migrations',
'Exdrals\\Identity\\Migrations' => 'vendor/exdrals/identity/database/migrations',
'ownHackathon\\Migrations' => 'database/migrations',
],

'all_or_nothing' => true,
Expand Down
3 changes: 2 additions & 1 deletion config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ class_exists(\Mezzio\Swoole\ConfigProvider::class)
},
// Default App module config
\ownHackathon\ConfigProvider::class,
\Exdrals\Shared\ConfigProvider::class,
\Exdrals\Core\ConfigProvider::class,
\Exdrals\Identity\ConfigProvider::class,

// Load application config in a pre-defined order in such a way that local settings
// overwrite global settings. (Loaded as first to last):
Expand Down
4 changes: 2 additions & 2 deletions config/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
use Exdrals\Shared\Domain\Enum\Router\RouteIdent;
use Mezzio\Application;
use Mezzio\MiddlewareFactory;
use ownHackathon\Shared\Handler\PingHandler;
use ownHackathon\Shared\Handler\SwaggerUIHandler;
use Psr\Container\ContainerInterface;
use Exdrals\Shared\Handler\PingHandler;
use Exdrals\Shared\Handler\SwaggerUIHandler;

return static function (Application $app, MiddlewareFactory $factory, ContainerInterface $container): void {
$app->get(
Expand Down
Loading