]> BookStack Code Mirror - bookstack/blob - config/database.php
Added basic system tests for markdown editor, Added extra test helpers
[bookstack] / config / database.php
1 <?php
2
3 return [
4
5     /*
6     |--------------------------------------------------------------------------
7     | PDO Fetch Style
8     |--------------------------------------------------------------------------
9     |
10     | By default, database results will be returned as instances of the PHP
11     | stdClass object; however, you may desire to retrieve records in an
12     | array format for simplicity. Here you can tweak the fetch style.
13     |
14     */
15
16     'fetch' => PDO::FETCH_CLASS,
17
18     /*
19     |--------------------------------------------------------------------------
20     | Default Database Connection Name
21     |--------------------------------------------------------------------------
22     |
23     | Here you may specify which of the database connections below you wish
24     | to use as your default connection for all database work. Of course
25     | you may use many connections at once using the Database library.
26     |
27     */
28
29     'default' => env('DB_CONNECTION', 'mysql'),
30
31     /*
32     |--------------------------------------------------------------------------
33     | Database Connections
34     |--------------------------------------------------------------------------
35     |
36     | Here are each of the database connections setup for your application.
37     | Of course, examples of configuring each database platform that is
38     | supported by Laravel is shown below to make development simple.
39     |
40     |
41     | All database work in Laravel is done through the PHP PDO facilities
42     | so make sure you have the driver for your particular database of
43     | choice installed on your machine before you begin development.
44     |
45     */
46
47     'connections' => [
48
49         'sqlite' => [
50             'driver'   => 'sqlite',
51             'database' => storage_path('database.sqlite'),
52             'prefix'   => '',
53         ],
54
55         'mysql' => [
56             'driver'    => 'mysql',
57             'host'      => env('DB_HOST', 'localhost'),
58             'database'  => env('DB_DATABASE', 'forge'),
59             'username'  => env('DB_USERNAME', 'forge'),
60             'password'  => env('DB_PASSWORD', ''),
61             'charset'   => 'utf8',
62             'collation' => 'utf8_unicode_ci',
63             'prefix'    => '',
64             'strict'    => false,
65         ],
66
67         'mysql_testing' => [
68             'driver'    => 'mysql',
69             'host'      => 'localhost',
70             'database'  => 'bookstack-test',
71             'username'  => 'bookstack-test',
72             'password'  => 'bookstack-test',
73             'charset'   => 'utf8',
74             'collation' => 'utf8_unicode_ci',
75             'prefix'    => '',
76             'strict'    => false,
77         ],
78
79         'pgsql' => [
80             'driver'   => 'pgsql',
81             'host'     => env('DB_HOST', 'localhost'),
82             'database' => env('DB_DATABASE', 'forge'),
83             'username' => env('DB_USERNAME', 'forge'),
84             'password' => env('DB_PASSWORD', ''),
85             'charset'  => 'utf8',
86             'prefix'   => '',
87             'schema'   => 'public',
88         ],
89
90         'sqlsrv' => [
91             'driver'   => 'sqlsrv',
92             'host'     => env('DB_HOST', 'localhost'),
93             'database' => env('DB_DATABASE', 'forge'),
94             'username' => env('DB_USERNAME', 'forge'),
95             'password' => env('DB_PASSWORD', ''),
96             'charset'  => 'utf8',
97             'prefix'   => '',
98         ],
99
100     ],
101
102     /*
103     |--------------------------------------------------------------------------
104     | Migration Repository Table
105     |--------------------------------------------------------------------------
106     |
107     | This table keeps track of all the migrations that have already run for
108     | your application. Using this information, we can determine which of
109     | the migrations on disk haven't actually been run in the database.
110     |
111     */
112
113     'migrations' => 'migrations',
114
115     /*
116     |--------------------------------------------------------------------------
117     | Redis Databases
118     |--------------------------------------------------------------------------
119     |
120     | Redis is an open source, fast, and advanced key-value store that also
121     | provides a richer set of commands than a typical key-value systems
122     | such as APC or Memcached. Laravel makes it easy to dig right in.
123     |
124     */
125
126     'redis' => [
127
128         'cluster' => false,
129
130         'default' => [
131             'host'     => '127.0.0.1',
132             'port'     => 6379,
133             'database' => 0,
134         ],
135
136     ],
137
138 ];