作者 燕梦迪

设置redis

@@ -6,31 +6,36 @@ @@ -6,31 +6,36 @@
6 6
7 return [ 7 return [
8 // 默认缓存驱动 8 // 默认缓存驱动
9 - 'default' => env('cache.driver', 'complex'), 9 + 'default' => env('cache.driver', 'redis'),
10 10
11 // 缓存连接方式配置 11 // 缓存连接方式配置
12 'stores' => [ 12 'stores' => [
13 - 'file' => [  
14 - // 驱动方式  
15 - 'type' => 'File',  
16 - // 缓存保存目录  
17 - 'path' => '',  
18 - // 缓存前缀  
19 - 'prefix' => '',  
20 - // 缓存有效期 0表示永久缓存  
21 - 'expire' => 0,  
22 - // 缓存标签前缀  
23 - 'tag_prefix' => 'tag:',  
24 - // 序列化机制 例如 ['serialize', 'unserialize']  
25 - 'serialize' => [],  
26 - ],  
27 - 'redis' => [  
28 - // 驱动方式  
29 - 'type' => 'Redis',  
30 - // 服务器地址  
31 - 'host'=> '127.0.0.1',  
32 - 'password' =>'bronet',  
33 - 'expire' => 0,  
34 - ], 13 +// 'file' => [
  14 +// // 驱动方式
  15 +// 'type' => 'File',
  16 +// // 缓存保存目录
  17 +// 'path' => '',
  18 +// // 缓存前缀
  19 +// 'prefix' => '',
  20 +// // 缓存有效期 0表示永久缓存
  21 +// 'expire' => 0,
  22 +// // 缓存标签前缀
  23 +// 'tag_prefix' => 'tag:',
  24 +// // 序列化机制 例如 ['serialize', 'unserialize']
  25 +// 'serialize' => [],
  26 +// ],
  27 +// 'redis' => [
  28 +// // 驱动方式
  29 +// 'type' => 'Redis',
  30 +// // 服务器地址
  31 +// 'host'=> '127.0.0.1',
  32 +// 'password' =>'bronet',
  33 +// 'expire' => 0,
  34 +// ],
  35 + 'type' => 'Redis',
  36 + // 服务器地址
  37 + 'host'=> '127.0.0.1',
  38 + 'password' =>'bronet',
  39 + 'expire' => 0,
35 ], 40 ],
36 ]; 41 ];