Sha256: 3820e75698af010d55e2aa8e228e67b54c4e1001fa0ce796a088f6d3f26c6517
Contents?: true
Size: 1.01 KB
Versions: 3
Compression:
Stored size: 1.01 KB
Contents
# Copyright © 2012 The Pennsylvania State University # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. rails_root = ENV['RAILS_ROOT'] || "#{File.dirname(__FILE__)}/../.." rails_env = ENV['RAILS_ENV'] || 'development' config = YAML::load(ERB.new(IO.read(File.join(Rails.root, 'config', 'redis.yml'))).result)['resque'].with_indifferent_access Resque.redis = Redis.new(host: config[:host], port: config[:port], thread_safe: true) Resque.inline = rails_env == 'test' Resque.redis.namespace = "#{Sufia::Engine.config.id_namespace}:#{rails_env}"
Version data entries
3 entries across 3 versions & 1 rubygems