我正在尝试设置 redmine 并创建了一个愚蠢的简单 database.yml,如下所示:
development:
adapter: sqlite3
database: db/development.sqlite3
pool: 5
timeout: 5000
production:
adapter: sqlite3
database: db/production.sqlite3
pool: 5
timeout: 5000
当我运行rake db:create
它时,它会按预期创建开发数据库。然而,当我运行rake db:migrate
它失败说:
development database is not configured!
db:migrate
如果database.yml
配置正确到可以创建数据库,为什么我不能运行?
编辑:
我运行RAILS_ENV=development rake db:migrate
并收到以下错误消息:
Invalid gemspec in [/var/lib/gems/1.8/specifications/mail-2.4.4.gemspec]: invalid date format in specification: "2012-03-14 00:00:00.000000000Z"
Invalid gemspec in [/var/lib/gems/1.8/specifications/tilt-1.3.3.gemspec]: invalid date format in specification: "2011-08-25 00:00:00.000000000Z"
NOTE: SourceIndex.new(hash) is deprecated; From /usr/share/redmine/config/../vendor/rails/railties/lib/rails/vendor_gem_source_index.rb:100 in `new'.
rake aborted!
ERROR: 'rake/rdoctask' is obsolete and no longer supported. Use 'rdoc/task' (available in RDoc 2.4.2+) instead.