سؤال

When I run rails s on cmd(windows) I got this error below... Can anyone hack this error? I'm using thin gem for local dev environment. What do I need to chage?

C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/config
uration.rb:115:in `read': No such file or directory - C:/Sites/project/config/da
tabase.yml (Errno::ENOENT)
        from C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/appli
cation/configuration.rb:115:in `database_configuration'
        from C:/Ruby193/lib/ruby/gems/1.9.1/gems/activerecord-3.2.11/lib/active_
record/railtie.rb:78:in `block (2 levels) in <class:Railtie>'
        from C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/comma
nds.rb:50:in `<top (required)>'
        from script/rails:6:in `require'
        from script/rails:6:in `<main>' 
هل كانت مفيدة؟

المحلول

Yes, the file C:/Sites/project/config/database.yml doesn't exist. Either move your database.yml to that location, or find the code that expects database.yml to be in that location and change it to point to where the file actually is.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top