34 lines
908 B
PHP
34 lines
908 B
PHP
<?php
|
|
|
|
require_once __DIR__ . '/vendor/autoload.php';
|
|
|
|
if (file_exists(__DIR__ . '/.env')) {
|
|
$dotenv = Dotenv\Dotenv::createImmutable(__DIR__);
|
|
$dotenv->safeLoad();
|
|
}
|
|
|
|
return [
|
|
'paths' => [
|
|
'migrations' => __DIR__ . '/db/migrations',
|
|
'seeds' => __DIR__ . '/db/seeds',
|
|
],
|
|
|
|
'environments' => [
|
|
'default_migration_table' => 'phinxlog',
|
|
'default_environment' => 'development',
|
|
|
|
'development' => [
|
|
'adapter' => $_ENV['DB_CONNECTION'] ?? 'mysql',
|
|
'host' => $_ENV['DB_HOST'] ?? 'localhost',
|
|
'name' => $_ENV['DB_DATABASE'] ?? '',
|
|
'user' => $_ENV['DB_USERNAME'] ?? '',
|
|
'pass' => $_ENV['DB_PASSWORD'] ?? '',
|
|
'port' => $_ENV['DB_PORT'] ?? 3306,
|
|
'charset' => 'utf8mb4',
|
|
'collation' => 'utf8mb4_unicode_ci',
|
|
],
|
|
],
|
|
|
|
'version_order' => 'creation',
|
|
];
|