@@ -28,7 +28,9 @@ after_fork do |server, worker| |
||
| 28 | 28 |
|
| 29 | 29 |
# If you are using Redis but not Resque, change this |
| 30 | 30 |
if defined?(Resque) |
| 31 |
- Resque.redis = ENV['REDISTOGO_URL'] |
|
| 31 |
+ uri = URI.parse(ENV["REDISTOGO_URL"]) |
|
| 32 |
+ redis = Redis.new(:host => uri.host, :port => uri.port, :password => uri.password) |
|
| 33 |
+ Resque.redis = redis |
|
| 32 | 34 |
Rails.logger.info('Connected to Redis')
|
| 33 | 35 |
end |
| 34 | 36 |
end |