I was looking to incorporate the DB capabilities of this hosting into my app (I'm using Camping). Unfortunately, I continue to receive an ActiveRecord::ConnectionNotEstablished.
I attempt to connect to the DB as follows:
def Texas.create Texas::Models::Base.establish_connection(YAML::load(File.read('data/database.yaml'))) Texas::Models.create_schema end
Note, that definition is not encapsulated within the Texas module, so my code looks something like:
"Camping.goes :texas
module Texas::Blah ... end
def Texas.create ... end"
This is my first time using camping, so if I need to put that statement elsewhere, I have no clue (and haven't seen any thorough tutorials).
Here are the details I use to attempt and connect to the DB:
adapter: mysql username: ai_wokkaflokka password: REDACTED database: ai_wokkaflokka
Any insight would be greatly appreciated. Thank you.