intridea/omniauth-ldap — Issue #6: uninitialized constant OmniAuth::Strategies::LDAP
Author: dauerbach
Created: 2011-12-14 20:45:23+00:00
State: open

I am trying to setup a simple rails 3.1 app with omniauth/ldap authentication. I have the following in my code:

in application.rb added:
require 'omniauth'
use OmniAuth::Strategies::LDAP,
:title => 'My LDAP AUTH',
:host => 'myhostname',
:port => 389,
:method => :plain,
:base => 'dc=hostnamepart1, dc=hostnamepart2, dc=edu',
:try_sasl => false,
:uid => 'uid',
:bind_dn => "anonymous",
:password => "let me in please"

Note: when aI try to require 'omniauth-ldap' I get a load error. Same for require 'omniauth/ldap'.

in Gemfile added:
gem 'omniauth', '~> 1.0.1'
gem 'omniauth-ldap', '~> 1.0.1'

(both gems are installed)

I must be missing something,but I don't know what.

When I start the server (in development mode) I get the following error in application.rb:

/Users/dauerbach/Dev/rails31apps/dodrc_photo_review/config/application.rb:17: uninitialized constant OmniAuth::Strategies::LDAP (NameError)

Any help MUCH appreciated...
dan