title: Rails 3.0 / net-ldap - works in irb, but not in app
body: <p>I've looked around and can't seem to find the answer to this... I'm trying to use net-ldap with rails. </p>
  
  <p>in irb, I can run a quick bind and it works:</p>
  
  <pre><code>irb(main):003:0&gt; ldap_con = Net::LDAP.new({:host =&gt; 'myhost.ad',
  irb(main):004:2*       :base =&gt; 'DC=myhost,DC=ad',
  irb(main):005:2*       :port =&gt; 389,:auth=&gt;{:method=&gt;:simple,:username =&gt; 'bsharpe@myhost.ad',
  irb(main):006:3*       :password =&gt; 'letmein' } } )
  =&gt; #&lt;Net::LDAP:0x292089f0 @host="myhost.ad", @open_connection=nil, @encryption=nil, @auth={:password=&gt;"letmein", :method=&gt;:simple, :username=&gt;"bsharpe@myhost.ad"}, @verbose=false, @port=389, @base="DC=myhost,DC=ad"&gt;
  irb(main):007:0&gt; ldap_con.bind
  =&gt; true
  </code></pre>
  
  <p>but if i run the app i get</p>
  
  <pre><code>no such file to load -- net/ldap
  </code></pre>
  
  <p>which is from my <code>require net/ldap</code>
  I checked <code>$LOAD_PATH</code> and it does contain <code>/usr/local/lib/ruby/gems/1.8/gems/net-ldap-0.1.1/lib</code></p>
  
  <p>What am I missing here?</p>