accounts/common/config/main.php

47 lines
1.4 KiB
PHP
Raw Normal View History

<?php
return [
'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
'components' => [
'cache' => [
'class' => yii\redis\Cache::class,
'redis' => 'redis',
],
'db' => [
'class' => yii\db\Connection::class,
'dsn' => 'mysql:host=db;dbname=' . getenv('MYSQL_DATABASE'),
'username' => getenv('MYSQL_USER'),
'password' => getenv('MYSQL_PASSWORD'),
'charset' => 'utf8',
],
'mailer' => [
'class' => yii\swiftmailer\Mailer::class,
'viewPath' => '@common/mail',
],
'security' => [
'passwordHashStrategy' => 'password_hash',
],
'redis' => [
'class' => yii\redis\Connection::class,
'hostname' => 'redis',
'password' => null,
'port' => 6379,
'database' => 0,
],
'amqp' => [
'class' => common\components\RabbitMQ\Component::class,
'host' => 'rabbitmq',
'port' => 5672,
'user' => getenv('RABBITMQ_DEFAULT_USER'),
'password' => getenv('RABBITMQ_DEFAULT_PASS'),
'vhost' => getenv('RABBITMQ_DEFAULT_VHOST'),
],
'guzzle' => [
'class' => GuzzleHttp\Client::class,
],
],
'aliases' => [
'@bower' => '@vendor/bower-asset',
'@npm' => '@vendor/npm-asset',
],
];