blog.robotex.de

Rails3: Getting it right with jruby and oracle

I finally got rails3 to work with jruby and oracle.

First, you'll need the right gem. Edit your Rails.root/Gemfile like this:

platforms :jruby do
  gem 'activerecord-jdbc-adapter'
end

Then change your Rails.root/config/database.yml to something like this:

development:
  adapter: jdbc
  driver: oracle.jdbc.driver.OracleDriver
  url: jdbc:oracle:thin:@[HOST]:1521:[SID]
  username: foo
  password: bar

Back