yii2-netdisk/config/db.php

20 lines
494 B
PHP
Raw Normal View History

<?php
2024-02-09 12:15:09 +08:00
use yii\db\Connection;
return [
2024-02-09 12:15:09 +08:00
'class' => Connection::class,
'dsn' => 'mysql:host='.$_ENV['DB_HOST'].';dbname='.$_ENV['DB_NAME'],
'username' => $_ENV['DB_USERNAME'],
'password' => $_ENV['DB_PASSWORD'],
2014-03-16 12:46:16 +08:00
'charset' => 'utf8',
2024-02-09 12:15:09 +08:00
'schemaMap' => [
'mysql' => SamIT\Yii2\MariaDb\Schema::class
]
// Schema cache options (for production environment)
//'enableSchemaCache' => true,
//'schemaCacheDuration' => 60,
//'schemaCache' => 'cache',
];