ruby on rails - Heroku throws error on db:migrate rake -
when i'm trying throw heroku run rake db:migrate
said in ror tutorial michael hartl throws me following:
running rake db:migrate on shielded-reaches-4728... up, run.2183 rake aborted! nomethoderror: undefined method 'configure' #<sampleapp::application:0x007efe8ced6138> /app/config/environments/production.rb:1:in '<top (required)>' /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/dependencies.rb:229:in 'require' /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/dependencies.rb:229:in 'block in require' /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/dependencies.rb:214:in 'load_dependency' /app/vendor/bundle/ruby/2.0.0/gems/activesupport-4.0.2/lib/active_support/dependencies.rb:229:in 'require' .. tasks: top => db:migrate => environment (see full trace running task --trace)
what can do?
update: production.rb file:
rails.application.configure config.cache_classes = true config.eager_load = true config.consider_all_requests_local = false config.action_controller.perform_caching = true config.serve_static_assets = false config.assets.js_compressor = :uglifier config.assets.compile = false config.assets.digest = true config.log_level = :info config.i18n.fallbacks = true config.active_support.deprecation = :notify config.log_formatter = ::logger::formatter.new config.active_record.dump_schema_after_migration = false end
it looks you've got this
... module sampleapp class application < rails::application ...
in application.rb
file. in case, in production.rb
file, need change
rails.application.configure
to
sampleapp::application.configure
Comments
Post a Comment