Enable octopus

This commit is contained in:
Piotr Sarnacki 2013-05-02 19:48:23 +02:00
parent 10c8d4b95f
commit f6d781c248

View File

@ -121,8 +121,15 @@ module Travis::Api
Travis::Database.connect Travis::Database.connect
if Travis.env == 'production' || Travis.env == 'staging' if Travis.env == 'production' || Travis.env == 'staging'
puts "is octopus working? #{::Octopus.enabled?}" # Octopus checks for Rails.env, just hardcode enabled?
Octopus.instance_eval do
def enabled?
true
end
end
ActiveRecord::Base.custom_octopus_connection = false ActiveRecord::Base.custom_octopus_connection = false
::Octopus.setup do |config| ::Octopus.setup do |config|
config.shards = { :follower => Travis.config.database_follower } config.shards = { :follower => Travis.config.database_follower }
config.environments = ['production', 'staging'] config.environments = ['production', 'staging']