redis.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. return
  3. [
  4. /**
  5. * ---------------------------------------------------------
  6. * Default
  7. * ---------------------------------------------------------
  8. *
  9. * Default configuration to use.
  10. */
  11. 'default' => 'localhost',
  12. /**
  13. * ---------------------------------------------------------
  14. * Configurations
  15. * ---------------------------------------------------------
  16. *
  17. * You can define as many Redis configurations as you want.
  18. *
  19. * host : IP address or hostname of the Redis server.
  20. * port : Port of the Redis server.
  21. * persistent: (optional) Set to true to make the connection persistent.
  22. * password : (optional) Password of the Redis server.
  23. * database : (optional) Database index to use for the connection.
  24. */
  25. 'configurations' =>
  26. [
  27. 'localhost' =>
  28. [
  29. 'host' => 'localhost',
  30. 'port' => 6379,
  31. 'persistent' => false,
  32. 'password' => '',
  33. 'database' => 0,
  34. ],
  35. 'cache' =>
  36. [
  37. 'host' => 'localhost',
  38. 'port' => 6379,
  39. 'persistent' => false,
  40. 'password' => '',
  41. 'database' => 1,
  42. ],
  43. 'session' =>
  44. [
  45. 'host' => 'localhost',
  46. 'port' => 6379,
  47. 'persistent' => false,
  48. 'password' => '',
  49. 'database' => 2,
  50. ],
  51. ],
  52. ];