sudo ls -l /var/run/redis/redis.sock
srwxrwx---. 1 redis redis 0 Aug 29 06:34 /var/run/redis/redis.sock
It is owned by the redis group, but I have added the apache user to this group.
sudo gpasswd -a apache redis
I don’t believe this is a permission issue, as I did check that the apache user can use the redis-cli.
sudo -u apache redis-cli -s /var/run/redis/redis.sock
redis /var/run/redis/redis.sock> ping
PONG