title: How to get list of mongodb databases and collections list from a ruby on rails app
body: <p>I am using Rails 3 and Mongoid gem. But I need to fill a combobox with the list of mongodb databases. In mongodb shell we can list databases with "show dbs" command. Also there is getDBNameList()  and db.getCollectionNames() commands in mongodb drivers. But I could not figure out how to use these commands from a ruby on rails app.</p>
  
  <p>Also I wonder; if I can get databases and collections list with using mongoid gem. Because I am sure that I had read that mongoid supports using more than one database, but I think it was model dependent.</p>
  
  <p>So what do you think; is there any solution or I have to use mongo-ruby-driver gem, not mongoid.</p>