title: rake aborted! can't convert nil into Hash
body: <p>rake aborted! Cannot load <code>Rails.application.database_configuration</code>: can't convert nil into Hash</p>
  
  <p>I am trying to deploy ruby on rails on openshift, and then i try to run rake db:migrate. Then i face this problem.</p>
  
  <p>I create the app with <a href="https://github.com/kohjx/TestYourCode.git" rel="nofollow">https://github.com/kohjx/TestYourCode.git</a> on openshift with ruby on rails + mysql 5.1</p>
  
  <p>Then i configure the config/database.yml </p>
  
  <pre><code>default: &amp;default
    #adapter: sqlite3
    adapter: mysql2
    pool: 5
    timeout: 5000
    database: "&lt;%=ENV['OPENSHIFT_APP_NAME']%&gt;"
    username: "&lt;%=ENV['OPENSHIFT_MYSQL_DB_USERNAME']%&gt;"
    password: "&lt;%=ENV['OPENSHIFT_MYSQL_DB_PASSWORD']%&gt;"
    host:     &lt;%=ENV['OPENSHIFT_MYSQL_DB_HOST']%&gt;
    port:     &lt;%=ENV['OPENSHIFT_MYSQL_DB_PORT']%&gt;
  
  
  
  development:
    &lt;&lt;: *default
    #database: db/development.sqlite3
  
  test:
    &lt;&lt;: *default
    #database: db/test.sqlite3
    database: testyourcode_test
  
  production:
    &lt;&lt;: *default
    secret_key_base: &lt;%= ENV["SECRET_KEY_BASE"] %&gt;
    #database: db/production.sqlite3
  </code></pre>
  
  <p>I setup the RAILS_ENV=development, but i can't figure out how to solve. Any help would be greatly appreciated!</p>