Heroku给了我“我们很抱歉,但出了点问题”。
我正在尝试将我的Rails项目部署到Heroku,它是基于sqlite的。
我在我的gem文件中有这些文件来修复以前的问题
group :production do
gem 'pg'
gem 'rails_12factor'
end
这是Heroku提供的日志,到目前为止没有错误
-----> Removing .DS_Store files
-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-2.0.0
-----> Installing dependencies using 1.6.3
Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4 --deployment
Fetching gem metadata from https://rubygems.org/..........
Fetching additional metadata from https://rubygems.org/..
Fetching git://github.com/thoughtbot/paperclip.git
Installing rake 10.3.2
Installing i18n 0.6.9
Installing minitest 5.3.5
Installing thread_safe 0.3.4
Installing builder 3.2.2
Installing erubis 2.7.0
Installing rack 1.5.2
Installing mime-types 1.25.1
Installing json 1.8.1
Installing polyglot 0.3.5
Installing arel 5.0.1.20140414130214
Installing sass 3.2.19
Installing thor 0.19.1
Installing execjs 2.2.0
Installing coffee-script-source 1.7.0
Installing orm_adapter 0.5.0
Installing highline 1.6.21
Installing hike 1.2.3
Installing multi_json 1.10.1
Installing icalendar 2.1.0
Installing options 2.3.2
Using bundler 1.6.3
Installing bcrypt 3.1.7
Installing tilt 1.4.1
Installing rails_serve_static_assets 0.0.2
Installing rails_stdout_logging 0.0.3
Installing will_paginate 3.0.6
Installing tzinfo 1.2.1
Installing rack-test 0.6.2
Installing warden 1.2.3
Installing rdoc 4.1.1
Installing treetop 1.4.15
Installing bourbon 3.2.3
Installing uglifier 2.5.1
Installing coffee-script 2.2.0
Installing progress_bar 1.0.2
Installing rails_12factor 0.0.2
Installing sprockets 2.11.0
Installing sdoc 0.4.0
Installing activesupport 4.1.1
Installing mail 2.5.4
Installing actionview 4.1.1
Installing climate_control 0.0.3
Installing activemodel 4.1.1
Installing jbuilder 2.1.1
Installing actionpack 4.1.1
Installing cocaine 0.5.4
Installing activerecord 4.1.1
Installing actionmailer 4.1.1
Installing sprockets-rails 2.1.3
Installing railties 4.1.1
Using paperclip 4.1.1 from git://github.com/thoughtbot/paperclip.git (at master)
Installing coffee-rails 4.0.1
Installing devise 3.2.4
Installing jquery-rails 3.1.0
Installing sass-rails 4.0.3
Installing rails 4.1.1
Installing turbolinks 2.2.2
Installing rails4-autocomplete 1.1.0
Installing pg 0.17.1
Your bundle is complete!
Gems in the groups development and test were not installed.
It was installed into ./vendor/bundle
Post-install message from icalendar:
HEADS UP! iCalendar 2.0 is not backwards-compatible with 1.x. Please see the README for the new syntax
Post-install message from rdoc:
Depending on your version of ruby, you may need to install ruby rdoc/ri data:
<= 1.8.6 : unsupported
= 1.8.7 : gem install rdoc-data; rdoc-data --install
= 1.9.1 : gem install rdoc-data; rdoc-data --install
>= 1.9.2 : nothing to do! Yay!
Bundle completed (19.02s)
Cleaning up the bundler cache.
-----> Preparing app for Rails asset pipeline
Running: rake assets:precompile
I, [2014-07-04T11:09:44.994721 #1465] INFO -- : Writing /tmp/build_015830e2-6769-413c-ae17-3c1d1e403a36/public/assets/application-ef6d9188f03ae958e0e7ebf51fab00fb.js
I, [2014-07-04T11:09:55.195306 #1465] INFO -- : Writing /tmp/build_015830e2-6769-413c-ae17-3c1d1e403a36/public/assets/application-dd93fb9eaa145c8045a2b6bf97786a72.css
Asset precompilation completed (19.06s)
Cleaning assets
Running: rake assets:clean
-----> WARNINGS:
You have not declared a Ruby version in your Gemfile.
To set your Ruby version add this line to your Gemfile:
ruby '2.0.0'
# See https://devcenter.heroku.com/articles/ruby-versions for more information.
No Procfile detected, using the default web server (webrick)
https://devcenter.heroku.com/articles/ruby-default-web-server
-----> Discovering process types
Procfile declares types -> (none)
Default types for Ruby -> console, rake, web, worker
-----> Compressing... done, 50.3MB
-----> Launching... done, v6
http://confguide.herokuapp.com/ deployed to Heroku
答案 0 :(得分:3)
从日志中看起来您还没有运行rake db:migrate
对于Heroku运行以下命令
heroku run rake db:migrate
https://devcenter.heroku.com/articles/getting-started-with-rails3#rake-and-database-migrations