Project

General

Profile

Defect #13270

Updated by Toshi MARUYAMA over 11 years ago

Doing a install wanted mysql even though all database.yml entries were mysql2. 

 version r11458 

 <pre> 
 About your application's environment 
 Ruby version                1.9.3 (x86_64-linux) 
 RubyGems version            1.8.25 
 Rack version                1.4 
 Rails version               3.2.12 
 Active Record version       3.2.12 
 Action Pack version         3.2.12 
 Active Resource version     3.2.12 
 Action Mailer version       3.2.12 
 Active Support version      3.2.12 
 Middleware                  Rack::Cache, ActionDispatch::Static, Rack::Lock, #<ActiveSupport::Cache::Strategy::LocalCache::Middleware:0x00000003b09818>, Rack::Runtime, Rack::MethodOverride, ActionDispatch::RequestId, Rails::Rack::Logger, ActionDispatch::ShowExceptions, ActionDispatch::DebugExceptions, ActionDispatch::RemoteIp, ActionDispatch::Callbacks, ActiveRecord::ConnectionAdapters::ConnectionManagement, ActiveRecord::QueryCache, ActionDispatch::Cookies, ActionDispatch::Session::CookieStore, ActionDispatch::Flash, ActionDispatch::ParamsParser, ActionDispatch::Head, Rack::ConditionalGet, Rack::ETag, ActionDispatch::BestStandardsSupport, OpenIdAuthentication 
 Application root            /usr/local/redmine-new/redmine-2.2-git 
 Environment                 production 
 Database adapter            mysql2 
 Database schema version     20121026003537 
 </pre> 

 <pre> 
 --- a/Gemfile 
 +++ b/Gemfile 
 @@ -44,9 +44,10 @@ if File.exist?(database_file) 
    if adapters.any? 
      adapters.each do |adapter| 
        case adapter 
 +        when /mysql2/ 
 +          gem "mysql2", "~> 0.3.11", :platforms => [:mri_19, :mingw_19] 
        when /mysql/ 
          gem "mysql", "~> 2.8.1", :platforms => [:mri_18, :mingw_18] 
 -          gem "mysql2", "~> 0.3.11", :platforms => [:mri_19, :mingw_19] 
          gem "activerecord-jdbcmysql-adapter", :platforms => :jruby 
        when /postgresql/ 
          gem "pg", ">= 0.11.0", :platforms => [:mri, :mingw] 
 </pre> 

 don't know if jruby jrmby activerecord-jdbcmysql-adapter is needed/available on mysql2.

Back