Hello! I can't find a way to have rails not use a database. I just left my database.yml file as it is. When I run my rails application that has no models, my browser says that it couldn't connect to a database. In environment.rb I uncommented the line config.frameworks -= [ :active_record, :active_resource, :action_mailer ] but then Webrick won't start. Sorry if this has already been posted or the solution is really simple, I couldn't find anything after about a half hour of searching and I've only been using rails for a few days. Thanks!
Hello! I can't find a way to have rails not use a database. I just left my database.yml file as it is. When I run my rails application that has no models, my browser says that it couldn't connect to a database. In environment.rb I uncommented the line config.frameworks -= [ :active_record, :active_resource, :action_mailer ]
That is about it but you need to also remove any other reference to those frameworks (eg in the config files or in the initializers)
Fred
Thanks for responding! Since I am new to rails, could you tell me where the references are in the config files or initializers that I should remove? I didn't add any references myself. Also, I don't really need to get rid of active resource or action mailer, but I am unsure if it is necessary. If I changed the line to config.frameworks -= [ :active_record ] would it be easier to remove active record or do active resource and action mailer rely on it?
Thanks for responding! Since I am new to rails, could you tell me where the references are in the config files or initializers that I should remove? I didn't add any references myself.
Anything that mentions any of the frameworks you are disabling, eg there are some that setup actionmailer.
Also, I don't really need to get rid of active resource or action mailer, but I am unsure if it is necessary. If I changed the line to config.frameworks -= [ :active_record ] would it be easier to remove active record or do active resource and action mailer rely on it?
they don't
Fred