Heroku推送仅失败到一个应用程序(分期)

时间:2013-12-23 08:32:25

标签: ruby-on-rails heroku

我正试图在heroku上推送我的临时应用程序,但是我收到了这个错误:

Fetching repository, done.
Counting objects: 10, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (6/6), done.
Writing objects: 100% (6/6), 551 bytes | 0 bytes/s, done.
Total 6 (delta 5), reused 0 (delta 0)

-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-1.9.3
-----> Installing dependencies using Bundler version 1.3.2
       Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin --deployment
       Using rake (10.1.0)
       Using i18n (0.6.5)
       Using multi_json (1.8.2)
       Using activesupport (3.2.14)
       Using builder (3.0.4)
       Using activemodel (3.2.14)
       Using erubis (2.7.0)
       Using journey (1.0.4)
       Using rack (1.4.5)
       Using rack-cache (1.2)
       Using rack-test (0.6.2)
       Using hike (1.2.3)
       Using tilt (1.4.1)
       Using sprockets (2.2.2)
       Using actionpack (3.2.14)
       Using mime-types (1.25)
       Using polyglot (0.3.3)
       Using treetop (1.4.15)
       Using mail (2.5.4)
       Using actionmailer (3.2.14)
       Using arel (3.0.3)
       Using tzinfo (0.3.38)
       Using activerecord (3.2.14)
       Using activeresource (3.2.14)
       Using atomic (1.1.14)
       Using auto_strip_attributes (2.0.4)
       Using bcrypt-ruby (3.1.2)
       Using json (1.8.1)
       Using carrierwave (0.9.0)
       Using chunky_png (1.2.9)
       Using coffee-script-source (1.6.3)
       Using execjs (2.0.2)
       Using coffee-script (2.2.0)
       Using rack-ssl (1.3.3)
       Using rdoc (3.12.2)
       Using thor (0.18.1)
       Using railties (3.2.14)
       Using coffee-rails (3.2.2)
       Using fssm (0.2.10)
       Using sass (3.2.12)
       Using compass (0.12.2)
       Using compass-rails (1.1.2)
       Using daemons (1.1.9)
       Using dalli (2.6.4)
       Using delayed_job (4.0.0)
       Using delayed_job_active_record (4.0.0)
       Using orm_adapter (0.5.0)
       Using thread_safe (0.1.3)
       Using warden (1.2.3)
       Using devise (3.2.1)
       Using excon (0.28.0)
       Using formatador (0.2.4)
       Using net-ssh (2.7.0)
       Using net-scp (1.1.2)
       Using mini_portile (0.5.2)
       Using nokogiri (1.6.0)
       Using ruby-hmac (0.4.0)
       Using fog (1.18.0)
       Using foreigner (1.6.0)
       Using haml (4.1.0.alpha.2)
       Using haml-rails (0.4)
       Using jquery-fileupload-rails (0.4.1)
       Using jquery-rails (3.0.4)
       Using jquery-ui-rails (4.1.0)
       Using jquery-validation-rails (1.11.1)
       Using kaminari (0.15.0)
       Using kgio (2.8.1)
       Using bundler (1.3.2)
       Using rails (3.2.14)
       Using mailboxer (0.11.0)
       Using memcachier (0.0.2)
       Using newrelic_rpm (3.6.9.171)
       Using xml-simple (1.1.2)
       Using paypal-sdk-core (0.2.6)
       Using paypal-sdk-adaptivepayments (1.105.0)
       Using pg (0.17.0)
       Using rails_serve_static_assets (0.0.1)
       Using rails_stdout_logging (0.0.3)
       Using rails_12factor (0.0.2)
       Using raindrops (0.12.0)
       Using rmagick (2.13.2)
       Using sass-rails (3.2.6)
       Using s3_direct_upload (0.1.6)
       Using shadowbox-rails (0.0.4)
       Using uglifier (2.3.1)
       Using unf_ext (0.0.6)
       Using unf (0.1.3)
       Using unicorn (4.7.0)
       Using yui-compressor (0.12.0)
       Your bundle is complete! It was installed into ./vendor/bundle
       Bundle completed (0.71s)
       Cleaning up the bundler cache.
-----> Writing config/database.yml to read from DATABASE_URL
       Could not detect rake tasks
       ensure you can run `$ bundle exec rake -P` against your app with no environment variables present
       and using the production group of your Gemfile.
       This may be intentional, if you expected rake tasks to be run
       cancel the build (CTRL+C) and fix the error then commit the fix:
       rake aborted!
       cannot load such file -- active_record/railtie
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/config/application.rb:4:in `require'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/config/application.rb:4:in `<top (required)>'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/Rakefile:5:in `require'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/Rakefile:5:in `<top (required)>'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/rake_module.rb:25:in `load'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/rake_module.rb:25:in `load_rakefile'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:501:in `raw_load_rakefile'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:82:in `block in load_rakefile'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:133:in `standard_exception_handling'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:81:in `load_rakefile'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:65:in `block in run'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:133:in `standard_exception_handling'
       /tmp/build_9abc0c91-cfad-4b19-b391-9a9a64e3582e/vendor/ruby-1.9.3/lib/ruby/1.9.1/rake/application.rb:63:in `run'
       vendor/ruby-1.9.3/bin/rake:38:in `<main>'
-----> Discovering process types
       Procfile declares types -> web, worker
       Default types for Ruby  -> console, rake

-----> Compressing... done, 29.2MB
-----> Launching... done, v36
-----> Deploy hooks scheduled, check output in your logs
       http://staging-grailed.herokuapp.com deployed to Heroku

To git@heroku.com:staging-grailed.git
   3323ae7..1b69562  master -> master

我能够在几个小时前用我的最后一次提交进行分段。这个新提交只有一些css和jquery更改,现在它已经坏了。 我能够创建一个新的应用程序(staging2)并部署代码。然后我尝试部署到生产(危险,我知道),这一切都很好。那么我的登台应用程序发生了什么?

更新:添加我的application.rb文件。

require File.expand_path('../boot', __FILE__)

# Pick the frameworks you want:
require "active_record/railtie"
require "action_controller/railtie"
require "action_mailer/railtie"
require "active_resource/railtie"
require "sprockets/railtie"
# require "rails/test_unit/railtie"

if defined?(Bundler)
  # If you precompile assets before deploying to production, use this line
  Bundler.require(*Rails.groups(:assets => %w(development test)))
  # If you want your assets lazily compiled in production, use this line
  # Bundler.require(:default, :assets, Rails.env)
end

module Grailed
  class Application < Rails::Application
    # Settings in config/environments/* take precedence over those specified here.
    # Application configuration should go into files in config/initializers
    # -- all .rb files in that directory are automatically loaded.

    # Custom directories with classes and modules you want to be autoloadable.
    # config.autoload_paths += %W(#{config.root}/extras)

    # Only load the plugins named here, in the order given (default is alphabetical).
    # :all can be used as a placeholder for all plugins not explicitly named.
    # config.plugins = [ :exception_notification, :ssl_requirement, :all ]

    # Activate observers that should always be running.
    # config.active_record.observers = :cacher, :garbage_collector, :forum_observer

    # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
    # Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
    # config.time_zone = 'Central Time (US & Canada)'

    # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
    # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
    # config.i18n.default_locale = :de


    #CONFIG LOGGER FOR UNICORN
    config.logger = Logger.new(STDOUT) 
    config.log_level = :INFO

    config.action_view.field_error_proc = Proc.new { |html_tag, instance| 
      "#{html_tag}".html_safe 
    }

    # Configure the default encoding used in templates for Ruby 1.9.
    config.encoding = "utf-8"

    # Configure sensitive parameters which will be filtered from the log file.
    config.filter_parameters += [:password]

    # Enable escaping HTML in JSON.
    config.active_support.escape_html_entities_in_json = true

    # Use SQL instead of Active Record's schema dumper when creating the database.
    # This is necessary if your schema can't be completely dumped by the schema dumper,
    # like if you have constraints or database-specific column types
    # config.active_record.schema_format = :sql

    # Enforce whitelist mode for mass assignment.
    # This will create an empty whitelist of attributes available for mass-assignment for all models
    # in your app. As such, your models will need to explicitly whitelist or blacklist accessible
    # parameters by using an attr_accessible or attr_protected declaration.
    config.active_record.whitelist_attributes = true

    # Enable the asset pipeline
    config.assets.enabled = true
    config.assets.paths << "#{Rails.root}/app/assets/fonts"
    # Add the fonts path
    config.assets.paths << Rails.root.join('app', 'assets', 'fonts')

    # Precompile additional assets
    config.assets.precompile += %w( .svg .eot .woff .ttf .otf )
    config.assets.precompile << /\.(?:svg|eot|woff|ttf|otf)$/

    # Version of your assets, change this if you want to expire all your assets
    config.assets.version = '1.0'


    # set sass to default stlyesheets
    #config.sass.preferred_syntax = :sass

    #heroku dont access db during precompile
    config.assets.initialize_on_precompile = false

    # setting new view templates to use haml by default
    config.generators do |g|
      g.template_engine :haml
    end
  end
end

0 个答案:

没有答案