You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

162 line
5.6KB

  1. <?php
  2. use Illuminate\Support\Str;
  3. return [
  4. /*
  5. |--------------------------------------------------------------------------
  6. | Default Database Connection Name
  7. |--------------------------------------------------------------------------
  8. |
  9. | Here you may specify which of the database connections below you wish
  10. | to use as your default connection for all database work. Of course
  11. | you may use many connections at once using the Database library.
  12. |
  13. */
  14. 'default' => env('DB_CONNECTION', 'mysql'),
  15. /*
  16. |--------------------------------------------------------------------------
  17. | Database Connections
  18. |--------------------------------------------------------------------------
  19. |
  20. | Here are each of the database connections setup for your application.
  21. | Of course, examples of configuring each database platform that is
  22. | supported by Laravel is shown below to make development simple.
  23. |
  24. |
  25. | All database work in Laravel is done through the PHP PDO facilities
  26. | so make sure you have the driver for your particular database of
  27. | choice installed on your machine before you begin development.
  28. |
  29. */
  30. 'connections' => [
  31. 'sqlite' => [
  32. 'driver' => 'sqlite',
  33. 'url' => env('DATABASE_URL'),
  34. 'database' => env('DB_DATABASE', database_path('database.sqlite')),
  35. 'prefix' => '',
  36. 'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true),
  37. ],
  38. 'testing' => [
  39. 'driver' => 'pgsql',
  40. 'url' => env('DATABASE_URL'),
  41. 'host' => env('DB_HOST_HTPMS', '127.0.0.1'),
  42. 'port' => env('DB_PORT_HTPMS', '5432'),
  43. 'database' => env('DB_DATABASE_HTPMS', 'forge'),
  44. 'username' => env('DB_USERNAME_HTPMS', 'forge'),
  45. 'password' => env('DB_PASSWORD_HTPMS', ''),
  46. 'charset' => 'utf8',
  47. 'prefix' => '',
  48. 'prefix_indexes' => true,
  49. 'search_path' => 'public',
  50. 'sslmode' => 'prefer',
  51. ],
  52. 'htpms' => [
  53. 'driver' => 'pgsql',
  54. 'url' => env('DATABASE_URL'),
  55. 'host' => env('DB_HOST_HTPMS', '127.0.0.1'),
  56. 'port' => env('DB_PORT_HTPMS', '5432'),
  57. 'database' => env('DB_DATABASE_HTPMS', 'forge'),
  58. 'username' => env('DB_USERNAME_HTPMS', 'forge'),
  59. 'password' => env('DB_PASSWORD_HTPMS', ''),
  60. 'charset' => 'utf8',
  61. 'prefix' => '',
  62. 'prefix_indexes' => true,
  63. 'search_path' => 'public',
  64. 'sslmode' => 'prefer',
  65. ],
  66. 'htpms_customer' => [
  67. 'driver' => 'pgsql',
  68. 'url' => env('DATABASE_URL'),
  69. 'host' => env('DB_HOST_HTPMS_CUSTOMER', '127.0.0.1'),
  70. 'port' => env('DB_PORT_HTPMS_CUSTOMER', '5432'),
  71. 'database' => env('DB_DATABASE_HTPMS_CUSTOMER', 'forge'),
  72. 'username' => env('DB_USERNAME_HTPMS_CUSTOMER', 'forge'),
  73. 'password' => env('DB_PASSWORD_HTPMS_CUSTOMER', ''),
  74. 'charset' => 'utf8',
  75. 'prefix' => '',
  76. 'prefix_indexes' => true,
  77. 'search_path' => 'public',
  78. 'sslmode' => 'prefer',
  79. ],
  80. 'htpms_system' => [
  81. 'driver' => 'pgsql',
  82. 'url' => env('DATABASE_URL'),
  83. 'host' => env('DB_HOST_HTPMS_SYSTEM', '127.0.0.1'),
  84. 'port' => env('DB_PORT_HTPMS_SYSTEM', '5432'),
  85. 'database' => env('DB_DATABASE_HTPMS_SYSTEM', 'forge'),
  86. 'username' => env('DB_USERNAME_HTPMS_SYSTEM', 'forge'),
  87. 'password' => env('DB_PASSWORD_HTPMS_SYSTEM', ''),
  88. 'charset' => 'utf8',
  89. 'prefix' => '',
  90. 'prefix_indexes' => true,
  91. 'search_path' => 'public',
  92. 'sslmode' => 'prefer',
  93. ],
  94. ],
  95. /*
  96. |--------------------------------------------------------------------------
  97. | Migration Repository Table
  98. |--------------------------------------------------------------------------
  99. |
  100. | This table keeps track of all the migrations that have already run for
  101. | your application. Using this information, we can determine which of
  102. | the migrations on disk haven't actually been run in the database.
  103. |
  104. */
  105. 'migrations' => 'migrations',
  106. /*
  107. |--------------------------------------------------------------------------
  108. | Redis Databases
  109. |--------------------------------------------------------------------------
  110. |
  111. | Redis is an open source, fast, and advanced key-value store that also
  112. | provides a richer body of commands than a typical key-value system
  113. | such as APC or Memcached. Laravel makes it easy to dig right in.
  114. |
  115. */
  116. 'redis' => [
  117. 'client' => env('REDIS_CLIENT', 'phpredis'),
  118. 'options' => [
  119. 'cluster' => env('REDIS_CLUSTER', 'redis'),
  120. 'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_') . '_database_'),
  121. ],
  122. 'default' => [
  123. 'url' => env('REDIS_URL'),
  124. 'host' => env('REDIS_HOST', '127.0.0.1'),
  125. 'username' => env('REDIS_USERNAME'),
  126. 'password' => env('REDIS_PASSWORD'),
  127. 'port' => env('REDIS_PORT', '6379'),
  128. 'database' => env('REDIS_DB', '0'),
  129. ],
  130. 'cache' => [
  131. 'url' => env('REDIS_URL'),
  132. 'host' => env('REDIS_HOST', '127.0.0.1'),
  133. 'username' => env('REDIS_USERNAME'),
  134. 'password' => env('REDIS_PASSWORD'),
  135. 'port' => env('REDIS_PORT', '6379'),
  136. 'database' => env('REDIS_CACHE_DB', '1'),
  137. ],
  138. ],
  139. ];