Chatwoot/config/initializers/redis.rb
Pranav Raj Sreepuram 2a34255e0b Initial Commit
Co-authored-by: Subin <subinthattaparambil@gmail.com>
Co-authored-by: Manoj <manojmj92@gmail.com>
Co-authored-by: Nithin <webofnithin@gmail.com>
2019-08-14 15:18:44 +05:30

13 lines
476 B
Ruby

require "redis"
#for reports
config = YAML::load_file(File.join(Rails.root, 'config', 'reports_redis.yml'))[Rails.env]
redis = Redis.new(host: config["host"], port: config["port"])
namespace = config["namespace"]
Nightfury.redis = Redis::Namespace.new(namespace << "reports", redis: redis)
=begin
Alfred - Used currently for Round Robin. Add here as you use it for more features
=end
$alfred = Redis::Namespace.new(namespace << "alfred", :redis => redis, :warning => true)