2016-01-02 19:13:18 +05:30
|
|
|
<?php
|
|
|
|
return [
|
2017-04-16 01:43:18 +05:30
|
|
|
'version' => '1.1.13-dev',
|
2016-01-02 19:13:18 +05:30
|
|
|
'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
|
|
|
|
'components' => [
|
|
|
|
'cache' => [
|
2016-11-27 20:11:39 +05:30
|
|
|
'class' => common\components\Redis\Cache::class,
|
2016-09-05 20:26:03 +05:30
|
|
|
'redis' => 'redis',
|
2016-01-02 19:13:18 +05:30
|
|
|
],
|
|
|
|
'db' => [
|
2016-07-17 21:43:40 +05:30
|
|
|
'class' => yii\db\Connection::class,
|
2016-12-04 18:04:32 +05:30
|
|
|
'dsn' => 'mysql:host=' . (getenv('DB_HOST') ?: 'db') . ';dbname=' . getenv('DB_DATABASE'),
|
|
|
|
'username' => getenv('DB_USER'),
|
|
|
|
'password' => getenv('DB_PASSWORD'),
|
2016-01-02 19:13:18 +05:30
|
|
|
'charset' => 'utf8',
|
2016-09-21 13:42:40 +05:30
|
|
|
'schemaMap' => [
|
|
|
|
'mysql' => common\db\mysql\Schema::class,
|
|
|
|
],
|
2016-01-02 19:13:18 +05:30
|
|
|
],
|
|
|
|
'mailer' => [
|
2016-07-17 21:43:40 +05:30
|
|
|
'class' => yii\swiftmailer\Mailer::class,
|
2016-01-02 19:13:18 +05:30
|
|
|
'viewPath' => '@common/mail',
|
2016-12-04 18:04:32 +05:30
|
|
|
'transport' => [
|
|
|
|
'class' => Swift_SmtpTransport::class,
|
|
|
|
'host' => 'ely.by',
|
|
|
|
'username' => getenv('SMTP_USER'),
|
|
|
|
'password' => getenv('SMTP_PASS'),
|
|
|
|
'port' => getenv('SMTP_PORT') ?: 587,
|
|
|
|
'encryption' => 'tls',
|
|
|
|
'streamOptions' => [
|
|
|
|
'ssl' => [
|
|
|
|
'allow_self_signed' => true,
|
|
|
|
'verify_peer' => false,
|
|
|
|
],
|
|
|
|
],
|
|
|
|
],
|
2016-01-02 19:13:18 +05:30
|
|
|
],
|
2016-11-22 04:17:41 +05:30
|
|
|
'sentry' => [
|
2016-12-08 02:21:01 +05:30
|
|
|
'class' => common\components\Sentry\Component::class,
|
2016-12-02 02:53:40 +05:30
|
|
|
'enabled' => !empty(getenv('SENTRY_DSN')),
|
|
|
|
'dsn' => getenv('SENTRY_DSN'),
|
2016-11-22 04:17:41 +05:30
|
|
|
'environment' => YII_ENV_DEV ? 'development' : 'production',
|
|
|
|
'client' => [
|
|
|
|
'curl_method' => 'async',
|
|
|
|
],
|
|
|
|
],
|
2016-01-03 05:48:37 +05:30
|
|
|
'security' => [
|
|
|
|
'passwordHashStrategy' => 'password_hash',
|
2016-02-14 23:20:10 +05:30
|
|
|
],
|
|
|
|
'redis' => [
|
2016-11-27 20:11:39 +05:30
|
|
|
'class' => common\components\Redis\Connection::class,
|
2016-12-04 18:04:32 +05:30
|
|
|
'hostname' => getenv('REDIS_HOST') ?: 'redis',
|
|
|
|
'password' => getenv('REDIS_PASS') ?: null,
|
|
|
|
'port' => getenv('REDIS_PORT') ?: 6379,
|
|
|
|
'database' => getenv('REDIS_DATABASE') ?: 0,
|
2016-02-14 23:20:10 +05:30
|
|
|
],
|
2016-04-12 03:16:44 +05:30
|
|
|
'amqp' => [
|
2016-09-16 03:58:28 +05:30
|
|
|
'class' => common\components\RabbitMQ\Component::class,
|
2016-12-04 18:04:32 +05:30
|
|
|
'host' => getenv('RABBITMQ_HOST') ?: 'rabbitmq',
|
|
|
|
'port' => getenv('RABBITMQ_PORT') ?: 5672,
|
|
|
|
'user' => getenv('RABBITMQ_USER'),
|
|
|
|
'password' => getenv('RABBITMQ_PASS'),
|
|
|
|
'vhost' => getenv('RABBITMQ_VHOST'),
|
2016-04-12 03:16:44 +05:30
|
|
|
],
|
2016-09-06 15:26:39 +05:30
|
|
|
'guzzle' => [
|
2016-09-16 03:58:28 +05:30
|
|
|
'class' => GuzzleHttp\Client::class,
|
2016-09-06 15:26:39 +05:30
|
|
|
],
|
2016-10-02 15:22:17 +05:30
|
|
|
'emailRenderer' => [
|
|
|
|
'class' => common\components\EmailRenderer::class,
|
|
|
|
'basePath' => '/images/emails',
|
|
|
|
],
|
2016-12-29 04:31:26 +05:30
|
|
|
'oauth' => [
|
|
|
|
'class' => api\components\OAuth2\Component::class,
|
|
|
|
'grantTypes' => ['authorization_code', 'client_credentials'],
|
|
|
|
'grantMap' => [
|
|
|
|
'authorization_code' => api\components\OAuth2\Grants\AuthCodeGrant::class,
|
|
|
|
'refresh_token' => api\components\OAuth2\Grants\RefreshTokenGrant::class,
|
|
|
|
'client_credentials' => api\components\OAuth2\Grants\ClientCredentialsGrant::class,
|
|
|
|
],
|
|
|
|
],
|
2016-01-02 19:13:18 +05:30
|
|
|
],
|
2017-05-18 04:39:26 +05:30
|
|
|
'container' => [
|
|
|
|
'definitions' => [
|
|
|
|
GuzzleHttp\ClientInterface::class => GuzzleHttp\Client::class,
|
|
|
|
],
|
|
|
|
],
|
2016-06-16 13:30:16 +05:30
|
|
|
'aliases' => [
|
|
|
|
'@bower' => '@vendor/bower-asset',
|
|
|
|
'@npm' => '@vendor/npm-asset',
|
|
|
|
],
|
2016-01-02 19:13:18 +05:30
|
|
|
];
|