Tuesday, July 2, 2013

MongoDB Standalone

OSFedora 18
Ruby2.0.0

Rather than directly dive into adding MongoDB to my application, I thought I'd try it standalone first and get the bugs worked out.

I started by following the example form the MongoDB web-site:

http://api.mongodb.org/ruby/current/

The example didn't "just work". I needed the 'bson_ext' gem installed.
My Gemfile is now:
source 'https://rubygems.org'

# gem 'rubygems'

gem 'mongo'
gem 'bson_ext'
To get mongodb running, I followed the directions here: mongodb-service-not-running-in-fedora I had to start the service by hand and then enable it to automatically start on boot. The example now passes!

No comments:

Post a Comment