Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法让 resque-web 与 Redis To Go 托管的 redis 实例一起工作?
更新:
@Nemo157 的建议是正确的。最终创建了一个 test-evn.rb 包含:
uri = URI.parse(" redis://XXXX@catfish.redistogo.com:9122") Resque.redis = Redis.new(:host => uri.host, :port => uri.port, :password => uri.password)
将您用于在应用程序中设置 redis 的配置文件传递给它,例如
resque-web ./environment.rb
其中environment.rb包含类似的内容:
environment.rb
Resque.redis = Redis.new(:host => "path.to.host", :port => 6379)
注意:我没有测试过这个,因为我所有的 redis 实例都是 on localhost,但这是我对它如何工作的理解。
localhost