我正在尝试推送Heroku的应用程序,我有一些错误,不知道该怎么做。开发模式(webrick服务器)工作正常,发送电子邮件等... 我正在使用activerecord-tableless发送电子邮件联系人。 这是我的ContactsController:
class ContactsController < ApplicationController
def new
@contact = Contact.new
end
def create
@contact = Contact.new(secure_params)
if @contact.valid?
UserMailer.contact_email(@contact).deliver_now
flash[:notice] = "Message sent from #{@contact.name}."
redirect_to root_path
else
flash.now[:error] = 'Cannot send message.'
render :new
end
end
private
def secure_params
params.require(:contact).permit(:name, :email, :content)
end
end
我的联系人课程:
class Contact < ActiveRecord::Base
has_no_table
column :name, :string
column :email, :string
column :content, :string
validates_presence_of :name, :email, :content
validates_format_of :email, :with => /\A[-a-z0-9_+\.]+\@([-a-z0-9]+\.)+[a-z0-9]{2,4}\z/i
validates_length_of :content, :maximum => 500
def self.column(name, sql_type = nil, default = nil, null = true)
type = "ActiveRecord::Type::#{sql_type.to_s.camelize}".constantize.new
tableless_options[:columns] << ActiveRecord::ConnectionAdapters::Column.new(name.to_s, default, type, null)
end
end
查看new.html.erb:
<% content_for :title do %>Contact<% end %>
<div class="distance">
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div align="center">
<h2>Send a message to Us</h2>
<%= simple_form_for @contact do |form| %>
<%= form.error_notification %>
<%= form.input :name, autofocus: true, placeholder: 'Enter name' %>
<%= form.input :email, placeholder: 'Enter email' %>
<%= form.input :content, as: :text, placeholder: 'Enter the content' %>
<%= form.button :submit, 'Submit', class: 'btn btn-info btn-lg' %>
<% end %>
</div>
</div>
</div>
的Gemfile:
source 'https://rubygems.org'
ruby '2.2.2'
gem 'rails', '4.2.4'
gem 'sass-rails', '~> 5.0'
gem 'uglifier', '>= 1.3.0'
gem 'coffee-rails', '~> 4.1.0'
gem 'jquery-rails'
gem 'turbolinks'
gem 'jbuilder', '~> 2.0'
group :development, :test do
gem 'byebug'
end
group :development do
gem 'web-console', '~> 2.0'
gem 'spring'
end
gem 'bootstrap-sass'
gem 'figaro', '>= 1.0.0.rc1'
gem 'simple_form'
gem 'font-awesome-sass', '~> 4.4.0'
gem "activerecord-tableless", ">= 1.3.4", git:'https://github.com/david135/activerecord-tableless.git'
group :development do
gem 'better_errors'
gem 'hub', :require=>nil
gem 'quiet_assets'
gem 'rails_layout'
end
group :development, :test do
gem 'sqlite3'
end
group :production do
gem 'pg'
gem 'rails_12factor'
gem 'thin'
end
database.yml中:
# SQLite version 3.x
# gem install sqlite3
#
# Ensure the SQLite 3 gem is defined in your Gemfile
# gem 'sqlite3'
#
default: &default
adapter: sqlite3
pool: 5
timeout: 5000
development:
<<: *default
database: db/development.sqlite3
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
test:
<<: *default
database: db/test.sqlite3
production:
<<: *default
database: db/production.sqlite3
production.rb
Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb.
# Code is not reloaded between requests.
config.cache_classes = true
# Eager load code on boot. This eager loads most of Rails and
# your application in memory, allowing both threaded web servers
# and those relying on copy on write to perform better.
# Rake tasks automatically ignore this option for performance.
config.eager_load = true
# Full error reports are disabled and caching is turned on.
config.consider_all_requests_local = false
config.action_controller.perform_caching = true
# Enable Rack::Cache to put a simple HTTP cache in front of your application
# Add `rack-cache` to your Gemfile before enabling this.
# For large-scale production use, consider using a caching reverse proxy like
# NGINX, varnish or squid.
# config.action_dispatch.rack_cache = true
# Disable serving static files from the `/public` folder by default since
# Apache or NGINX already handles this.
config.serve_static_files = ENV['RAILS_SERVE_STATIC_FILES'].present?
# Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier
# config.assets.css_compressor = :sass
# Do not fallback to assets pipeline if a precompiled asset is missed.
config.assets.compile = false
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
# yet still be able to expire them through the digest params.
config.assets.digest = true
# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb
# Specifies the header that your server uses for sending files.
# config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
# config.force_ssl = true
# Use the lowest log level to ensure availability of diagnostic information
# when problems arise.
config.log_level = :debug
# Prepend all log lines with the following tags.
# config.log_tags = [ :subdomain, :uuid ]
# Use a different logger for distributed setups.
# config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)
# Use a different cache store in production.
# config.cache_store = :mem_cache_store
# Enable serving of images, stylesheets, and JavaScripts from an asset server.
# config.action_controller.asset_host = 'http://assets.example.com'
# Ignore bad email addresses and do not raise email delivery errors.
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
# config.action_mailer.raise_delivery_errors = false
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation cannot be found).
config.i18n.fallbacks = true
# Send deprecation notices to registered listeners.
config.active_support.deprecation = :notify
config.action_mailer.smtp_settings = {
address: "smtp.gmail.com",
port: 587,
domain: Rails.application.secrets.domain_name,
authentication: "plain",
enable_starttls_auto: true,
user_name: Rails.application.secrets.email_provider_username,
password: Rails.application.secrets.email_provider_password
}
# ActionMailer Config
config.action_mailer.default_url_options = { :host => Rails.application.secrets.domain_name }
config.action_mailer.delivery_method = :smtp
config.action_mailer.perform_deliveries = true
config.action_mailer.raise_delivery_errors = false
config.action_mailer.default :charset => "utf-8"
config.action_mailer.smtp_settings = {
address: "smtp.gmail.com",
port: 587,
domain: ENV["DOMAIN_NAME"],
authentication: "plain",
enable_starttls_auto: true,
user_name: ENV["GMAIL_USERNAME"],
password: ENV["GMAIL_PASSWORD"]
}
# Use default logging formatter so that PID and timestamp are not suppressed.
config.log_formatter = ::Logger::Formatter.new
# Do not dump schema after migrations.
config.active_record.dump_schema_after_migration = false
end
我正在使用宝石figaro和我的application.yml是:
GMAIL_USERNAME: 'XXXXXXX'
GMAIL_PASSWORD: 'XXXXXXX'
DOMAIN_NAME: 'XXXXXXX'
OWNER_EMAIL: 'XXXXXXX@mail.com'
当我尝试推送heroku时出现此错误:
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/motaprojectlive.git'
当我尝试跑步时:
$ heroku run rails console
Running `rails console` attached to terminal... up, run.5541
PG::UndefinedObject: ERROR: type "string" does not exist
LINE 1: SELECT 'string'::regtype::oid
^
: SELECT 'string'::regtype::oid
/app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in `async_exec': PG::UndefinedObject: ERROR: type "string" does not exist (ActiveRecord::StatementInvalid)
LINE 1: SELECT 'string'::regtype::oid
^
: SELECT 'string'::regtype::oid
from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in `block in execute'
$ heroku logs -t
2015-09-15T05:32:26.718951+00:00 app[web.1]: => Booting Thin
2015-09-15T05:32:26.718975+00:00 app[web.1]: => Rails 4.2.4 application starting in production on http://0.0.0.0:47284
2015-09-15T05:32:26.718977+00:00 app[web.1]: => Run `rails server -h` for more startup options
2015-09-15T05:32:26.718978+00:00 app[web.1]: => Ctrl-C to shutdown server
2015-09-15T05:32:26.718979+00:00 app[web.1]: PG::UndefinedObject: ERROR: type "string" does not exist
2015-09-15T05:32:26.718981+00:00 app[web.1]: LINE 1: SELECT 'string'::regtype::oid
2015-09-15T05:32:26.718982+00:00 app[web.1]: ^
2015-09-15T05:32:26.718983+00:00 app[web.1]: : SELECT 'string'::regtype::oid
2015-09-15T05:32:26.719031+00:00 app[web.1]: Exiting
2015-09-15T05:32:26.719097+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in `async_exec': PG::UndefinedObject: ERROR: type "string" does not exist (ActiveRecord::StatementInvalid)
2015-09-15T05:32:26.719099+00:00 app[web.1]: LINE 1: SELECT 'string'::regtype::oid
2015-09-15T05:32:26.719100+00:00 app[web.1]: ^
2015-09-15T05:32:26.719110+00:00 app[web.1]: : SELECT 'string'::regtype::oid
2015-09-15T05:32:26.719114+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/abstract_adapter.rb:473:in `block in log'
2015-09-15T05:32:26.719113+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in `block in execute'
2015-09-15T05:32:26.719117+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/abstract_adapter.rb:467:in `log'
2015-09-15T05:32:26.719115+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
2015-09-15T05:32:26.719120+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql/database_statements.rb:154:in `execute'
2015-09-15T05:32:26.719121+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.4/lib/active_record/connection_adapters/postgresql_adapter.rb:393:in `lookup_cast_type'
2015-09-15T05:32:26.719122+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/bundler/gems/activerecord-tableless-800393c52bd2/lib/activerecord-tableless.rb:93:in `column'
2015-09-15T05:32:26.719125+00:00 app[web.1]: from /app/app/models/contact.rb:3:in `<class:Contact>'
2015-09-15T05:32:26.719126+00:00 app[web.1]: from /app/app/models/contact.rb:1:in `<top (required)>'
2015-09-15T05:32:26.719132+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `block in require'
2015-09-15T05:32:26.719129+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
2015-09-15T05:32:26.719142+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:317:in `depend_on'
2015-09-15T05:32:26.719139+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:360:in `require_or_load'
2015-09-15T05:32:26.719135+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:240:in `load_dependency'
2015-09-15T05:32:26.719147+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:472:in `block (2 levels) in eager_load!'
2015-09-15T05:32:26.719136+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
2015-09-15T05:32:26.719187+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:471:in `block in eager_load!'
2015-09-15T05:32:26.719145+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:233:in `require_dependency'
2015-09-15T05:32:26.719191+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:469:in `each'
2015-09-15T05:32:26.719192+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:469:in `eager_load!'
2015-09-15T05:32:26.719150+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:471:in `each'
2015-09-15T05:32:26.719193+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/engine.rb:346:in `eager_load!'
2015-09-15T05:32:26.719196+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/application/finisher.rb:56:in `block in <module:Finisher>'
2015-09-15T05:32:26.719197+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/initializable.rb:30:in `instance_exec'
2015-09-15T05:32:26.719195+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/application/finisher.rb:56:in `each'
2015-09-15T05:32:26.719198+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/initializable.rb:30:in `run'
2015-09-15T05:32:26.719199+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/initializable.rb:55:in `block in run_initializers'
2015-09-15T05:32:26.719200+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:226:in `block in tsort_each'
2015-09-15T05:32:26.719202+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:429:in `each_strongly_connected_component_from'
2015-09-15T05:32:26.719201+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component'
2015-09-15T05:32:26.719204+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:347:in `block in each_strongly_connected_component'
2015-09-15T05:32:26.719205+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:345:in `each'
2015-09-15T05:32:26.719207+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:345:in `each_strongly_connected_component'
2015-09-15T05:32:26.719206+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:345:in `call'
2015-09-15T05:32:26.719210+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:224:in `tsort_each'
2015-09-15T05:32:26.719211+00:00 app[web.1]: from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/tsort.rb:203:in `tsort_each'
2015-09-15T05:32:26.719212+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/initializable.rb:54:in `run_initializers'
2015-09-15T05:32:26.719213+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/application.rb:352:in `initialize!'
2015-09-15T05:32:26.719215+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
2015-09-15T05:32:26.719214+00:00 app[web.1]: from /app/config/environment.rb:5:in `<top (required)>'
2015-09-15T05:32:26.719216+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `block in require'
2015-09-15T05:32:26.719221+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
2015-09-15T05:32:26.719222+00:00 app[web.1]: from /app/config.ru:3:in `block in <main>'
2015-09-15T05:32:26.719223+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/builder.rb:55:in `instance_eval'
2015-09-15T05:32:26.719224+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/builder.rb:55:in `initialize'
2015-09-15T05:32:26.719218+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:240:in `load_dependency'
2015-09-15T05:32:26.719227+00:00 app[web.1]: from /app/config.ru:in `new'
2015-09-15T05:32:26.719228+00:00 app[web.1]: from /app/config.ru:in `<main>'
2015-09-15T05:32:26.719229+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/builder.rb:49:in `eval'
2015-09-15T05:32:26.719236+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/server.rb:299:in `build_app_and_options_from_config'
2015-09-15T05:32:26.719232+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/builder.rb:49:in `new_from_string'
2015-09-15T05:32:26.719239+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/server.rb:208:in `app'
2015-09-15T05:32:26.719233+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/builder.rb:40:in `parse_file'
2015-09-15T05:32:26.719242+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/server.rb:61:in `app'
2015-09-15T05:32:26.719246+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/server.rb:272:in `start'
2015-09-15T05:32:26.719243+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/server.rb:336:in `wrapped_app'
2015-09-15T05:32:26.719248+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/server.rb:80:in `start'
2015-09-15T05:32:26.719251+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:80:in `block in server'
2015-09-15T05:32:26.719255+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:75:in `server'
2015-09-15T05:32:26.719254+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:75:in `tap'
2015-09-15T05:32:26.719258+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
2015-09-15T05:32:26.719263+00:00 app[web.1]: from bin/rails:8:in `require'
2015-09-15T05:32:26.719261+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.4/lib/rails/commands.rb:17:in `<top (required)>'
2015-09-15T05:32:26.719266+00:00 app[web.1]: from bin/rails:8:in `<main>'
2015-09-15T05:32:27.834264+00:00 heroku[web.1]: Process exited with status 1
2015-09-15T05:32:27.853661+00:00 heroku[web.1]: State changed from starting to crashed
2015-09-15T08:20:07.379945+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=motaprojectlive.herokuapp.com request_id=c8265c44-6398-44f4-ae08-a2077171ac55 fwd="46.27.166.60" dyno= connect= service= status=503 bytes=
2015-09-15T08:23:47.348699+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=motaprojectlive.herokuapp.com request_id=576b4f28-174f-4b1e-8700-5053fbf3323c fwd="46.27.166.60" dyno= connect= service= status=503 bytes=
2015-09-15T09:36:03.654458+00:00 heroku[api]: Starting process with command `rails console` by romenigld@gmail.com
2015-09-15T09:36:15.126378+00:00 heroku[run.3618]: Awaiting client
2015-09-15T09:36:15.162910+00:00 heroku[run.3618]: Starting process with command `rails console`
2015-09-15T09:36:15.516485+00:00 heroku[run.3618]: State changed from starting to up
2015-09-15T09:36:20.194081+00:00 heroku[run.3618]: State changed from up to complete
2015-09-15T09:36:20.183530+00:00 heroku[run.3618]: Process exited with status 1
2015-09-15T09:50:59.737668+00:00 heroku[api]: Starting process with command `rails console` by romenigld@gmail.com
2015-09-15T09:51:15.542149+00:00 heroku[run.1439]: Awaiting client
2015-09-15T09:51:15.750707+00:00 heroku[run.1439]: State changed from starting to up
2015-09-15T09:51:15.854508+00:00 heroku[run.1439]: Starting process with command `rails console`
2015-09-15T09:51:21.470332+00:00 heroku[run.1439]: State changed from up to complete
2015-09-15T09:51:21.462321+00:00 heroku[run.1439]: Process exited with status 1
2015-09-15T09:52:05.112988+00:00 heroku[slug-compiler]: Slug compilation started
2015-09-15T09:52:05.113010+00:00 heroku[slug-compiler]: Slug compilation error: slug archive could not be created
2015-09-15T10:15:15.727423+00:00 heroku[api]: Starting process with command `rails console` by romenigld@gmail.com
2015-09-15T10:15:26.853219+00:00 heroku[run.5541]: Awaiting client
2015-09-15T10:15:26.885072+00:00 heroku[run.5541]: Starting process with command `rails console`
2015-09-15T10:15:27.062819+00:00 heroku[run.5541]: State changed from starting to up
2015-09-15T10:15:31.889775+00:00 heroku[run.5541]: State changed from up to complete
2015-09-15T10:15:31.877044+00:00 heroku[run.5541]: Process exited with status 1
答案 0 :(得分:0)
你的模特错了。
这些行不应该存在。
column :name, :string
column :email, :string
column :content, :string
只需删除它们即可。