【发布时间】:2016-10-03 07:53:32
【问题描述】:
当我尝试通过 heroku run rake 迁移到 heroku 我收到以下错误:
Running rake on ⬢ friends-clique... up, run.8185
/app/vendor/bundle/ruby/2.2.0/gems/bootstrap-4.0.0.alpha3/lib/bootstrap/version.rb:2: warning: already initialized constant Bootstrap::VERSION
/app/vendor/bundle/ruby/2.2.0/gems/bootstrap-sass-3.3.6/lib/bootstrap-sass/version.rb:2: warning: previous definition of VERSION was here
/app/vendor/bundle/ruby/2.2.0/gems/bootstrap-4.0.0.alpha3/lib/bootstrap/version.rb:3: warning: already initialized constant Bootstrap::BOOTSTRAP_SHA
/app/vendor/bundle/ruby/2.2.0/gems/bootstrap-sass-3.3.6/lib/bootstrap-sass/version.rb:3: warning: previous definition of BOOTSTRAP_SHA was here
DEPRECATION WARNING: The configuration option `config.serve_static_assets` has been renamed to `config.serve_static_files` to clarify its role (it merely enables serving everything in the `public` folder and is unrelated to the asset pipeline). The `serve_static_assets` alias will be removed in Rails 5.0. Please migrate your configuration files accordingly. (called from block in <top (required)> at /app/config/environments/production.rb:82)
Abort testing: Your Rails environment is running in production mode!
我以为 heroku 是在生产模式下运行的,刚刚发生了什么?
【问题讨论】:
-
您是否在本地以生产模式运行项目?
-
你和 Bootstrap 有 gem 冲突,检查你的 gemfile,也试试
heroku run bundle install -
您正在运行的确切命令是什么?
-
你的 Heroku 日志是怎么说的?
-
你在 heroku 上的
RACK_ENV和RAILS_ENV是什么?您可以通过运行heroku config来获取此信息。
标签: ruby-on-rails heroku database-migration production-environment