Closed mouyong closed 1 year ago
Laravel config/database.php: redis client is phpredis.
Laravel Cache use redis cache.
Had you added redis to the php.ini that you send with the -c
option.
If Redis is in /etc/php/x.x/cli/conf.d/
dir, will be loaded automatically.
If it's added in the /etc/php/x.x/cli/php.ini
, and you use another php.ini
, you need to add to that one.
you are right. When I use php -c php.ini, I need add extension = /path/to/redis.so
in php.ini
If you create in /etc/php/x.x/cli/conf.d/redis.ini
, with extension = /path/to/redis.so
.
Will be loaded automatically.
Also if you use Workerman, and only 1 server, we can create a Workerman cache. And we don't need Redis for cache.
And without the -c
option, will use your normal cli/php.ini
.
With all your extensions and configs.
maybe you are right. add redis.so
to php.ini.
php.ini content: https://github.com/joanhey/AdapterMan/blob/master/cli-php.ini