0
0

main.php 980 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. return [
  3. 'aliases' => [
  4. '@bower' => '@vendor/bower-asset',
  5. '@npm' => '@vendor/npm-asset',
  6. ],
  7. 'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
  8. 'sourceLanguage' => 'en',
  9. 'language' => 'zh-CN',
  10. 'components' => [
  11. // 新添加的
  12. 'Amqp' => [
  13. 'class' => 'components\service\Amqp',
  14. 'host' => '127.0.0.1',
  15. 'port' => '5672',
  16. 'user' => 'guest',
  17. 'pass' => 'Guest',
  18. ],
  19. 'cache' => [
  20. 'class' => 'yii\caching\FileCache',
  21. ],
  22. 'redis' => [
  23. 'class' => 'yii\redis\Connection',
  24. 'hostname' => '127.0.0.1',
  25. 'port' => 6378,
  26. 'database' => 0,
  27. 'password' => 'redis12078',
  28. ],
  29. 'i18n' => [
  30. 'translations' => [
  31. '*' => [
  32. 'class' => 'yii\i18n\PhpMessageSource',
  33. 'basePath'=>'@common/messages',
  34. 'fileMap' => [
  35. 'common' => 'common.php',
  36. 'error' => 'errorCode.php',
  37. ],
  38. ],
  39. ],
  40. ],
  41. ],
  42. ];