Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
23 lines (16 sloc) 635 Bytes

MongoMapper ORM for Devise


Use the rails3 branch of MongoMapper, and add devise-mongo_mapper to your Gemfile

gem 'mongo_mapper',
  :git    => 'git://',
  :branch => 'rails3'
gem 'devise-mongo_mapper',
  :git    => 'git://

Comment out the current ORM in config/initializers/devise.rb, and add:

require 'devise/orm/mongo_mapper'

Configure your model:

class User
  include MongoMapper::Document
  plugin MongoMapper::Devise
  devise :registerable, :database_authenticatable, :recoverable
Jump to Line
Something went wrong with that request. Please try again.