It appears that db_config['database'] is empty, even though
db:load_config checks for that condition. I have a proper database.yml
both locally and on my EC2 instance in /mnt/app/config/, so I don't
quite understand why it's failing.
Any ideas? Many thanks.
Paul Dowman
unread,
Aug 10, 2008, 2:16:45 PM8/10/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ec2-on-rai...@googlegroups.com
Hi Scott,
Perhaps it's confused about what the value of RAILS_ENV should be. When you run the ec2onrails:setup task, it uses the value of :rails_env from the deploy.rb file as the RAILS_ENV that mongrel (and other rails-related processes) should use.
Log into the instance by ssh and type "rails_env" to see what the value is, and make sure your database.yml has a section with that name.
Paul
Joshua Kolden
unread,
Aug 20, 2008, 1:39:39 PM8/20/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ec2-on-rails-discuss
I'm having this problem too. If I ssh to the instance and echo
$RAILS_ENV I see nothing, but I'm not confident that indicates
anything. Anyone have a solution yet?
> ** [out :: ec2-xxxxx.compute-1.amazonaws.com] :YouhaveanerrorinyourSQLsyntax; check the manual that corresponds toyourMySQL
> server version for the rightsyntaxto use near '' at line 1
> command finished
> command "mysql -u root -e \"create database if not exists ;\"" failed
> on ec2-xxxxx.compute-1.amazonaws.com > ---
>
> It appears that db_config['database'] is empty, even though
> db:load_config checks for that condition. Ihavea proper database.yml
Joshua Kolden
unread,
Aug 20, 2008, 1:59:15 PM8/20/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to ec2-on-rails-discuss
Actually if I run RAILS_ENV as described above, I do get "production".