0

FreeBSD 9.2 Apache 2.4 + Passenger Trying to start Redmine 2.3.2

Error:

/usr/local/lib/ruby/gems/1.9/gems/activerecord-3.2.13/lib/active_record
 /connection_adapters/abstract/connection_specification.rb:47:in    
 `resolve_hash_connection': database configuration does not specify
adapter (ActiveRecord::AdapterNotSpecified)

I found that if I change adapter from adapter: mysql2 to adapter:mysql2 (remove space after ":" ) then this error gone, however then I have another error:

/usr/local/lib/ruby/gems/1.9/gems/bundler-1.3.5/lib/bundler/dsl.rb:33:in
`rescue in eval_gemfile': Gemfile syntax error:
(Bundler::GemfileError)

So I have to make it work when adapter: mysql2 is configured, so I have to solve ActiveRecord::AdapterNotSpecified error problem somehow else, not by removing space there.

Any ideas?

RubyGems Environment:
  - RUBYGEMS VERSION: 1.8.25
  - RUBY VERSION: 1.9.3 (2013-06-27 patchlevel 448) [amd64-freebsd9]
  - INSTALLATION DIRECTORY: /usr/local/lib/ruby/gems/1.9
  - RUBY EXECUTABLE: /usr/local/bin/ruby19
  - EXECUTABLE DIRECTORY: /usr/local/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - amd64-freebsd-9
  - GEM PATHS:
     - /usr/local/lib/ruby/gems/1.9
     - /root/.gem/ruby/1.9
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
Adi Inbar
  • 12,097
  • 13
  • 56
  • 69
  • I found that it trying to get adapter from the section development instead of production. The development section is commented in my config file. But why it try to get connection from there? I don't understand how to say to take it from production section. I know about environment, but I don't understand the basic things - how to configure production environment for starting redmine from browser (for cgi script)? – user2692911 Aug 18 '13 at 07:04

1 Answers1

0

It seems to me that you do not set variable RAILS_ENV as production. Try to write in starting script RAILS_ENV=production or setup the variable globally

gotva
  • 5,919
  • 2
  • 25
  • 35