views:

25

answers:

0

Hi,

I'm new to Rack and try to get my head around it running Ruby on Rails 3.0.0.beta4.

I'm starting a Rack app in the config.ru file but would like to use a variable there that is stored in my database. Is it even possible to get a database value back before the application is loaded or am I missing the point completely?

I'm using the Rack Google Analytics gem and would like to get the UA key from the database:

require "rack-google-analytics"
use Rack::GoogleAnalytics, :tracker => "UA-xxxxx-x"

Thanks!