首先复制一个 config/cache 配置文件到相应位置(tp6shop-singwa在app/api/config)
把这个位置改成Redis
在下面配置一下redis
'redis' => [
'host' => '127.0.0.1',
'port' => 6379,
'password' => '',
],
更多配置项在↓
TP-Redis基础类库在
tp6shop\vendor\topthink\framework\src\think\cache\driver\Redis.php