/lsredis

Lemonstand Redis caching module

Primary LanguagePHP

lsredis

Lemonstand Redis module. Uses the Predis library ( version 0.8.3 ) to allow Redis as an option for caching in Lemonstand.

Installation

  • Clone/download lsredis into the modules directory of your Lemonstand installation
  • Add the following to your config.php file, which is located in the config folder at the base of your installation. Please change <host> and <port> to match your needs. For a default Redis install, '127.0.0.1:6379' should work.
$CONFIG['CACHING'] = array(
  'CLASS_NAME'          => 'LsRedis_RedisCache',  
  'DISABLED'            => false, 
  'PARAMS'              => array(
    'SERVERS' => array( '<host>:<port>'),
    'TTL'     => 3600
  )
);

Note

Daniele Alessandri (twitter) is the author of Predis. I am merely using it as the library to make the connection.

License

The code for lsredis is distributed under the terms of the MIT license (see LICENSE).