This commit is contained in:
Juan Pablo Vial
2023-07-24 20:41:38 -04:00
parent 6ab24c8961
commit be33305cf1
612 changed files with 11436 additions and 107 deletions

View File

@ -0,0 +1,24 @@
<?php
include_once dirname(__DIR__) . '/bootstrap/dotenv.php';
function buildDatabaseConfig(): array {
$arr = [
'mysql' => [
'host' => $_ENV['MYSQL_HOST'],
'database' => $_ENV['MYSQL_DATABASE'],
'username' => $_ENV['MYSQL_USER'],
'password' => $_ENV['MYSQL_PASSWORD']
],
'mysql_copy' => [
'host' => 'localhost',
'database' => 'incoviba3',
'username' => 'incoviba',
'password' => $_ENV['MYSQL_PASSWORD']
]
];
if (isset($_ENV['MYSQL_PORT'])) {
$arr['mysql']['port'] = $_ENV['MYSQL_PORT'];
}
return $arr;
}
return buildDatabaseConfig();