简体   繁体   中英

Rails 4 - Assets routing error

I am transitioning from Heroku to AWS Elastic Beanstalk and in my logs I keep seeing this error with .css and .js assets.

Rails 4.2 Ruby 2.2.5

ActionController::RoutingError (No route matches [GET] "/assets/application-be8de4c1a8d12cb784028972b73fe7e23d4acc55757e3d297ef5e3db4161c369.css"):
vendor/bundle/gems/actionpack-4.2.2/lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
vendor/bundle/gems/actionpack-4.2.2/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
vendor/bundle/gems/railties-4.2.2/lib/rails/rack/logger.rb:38:in `call_app'
vendor/bundle/gems/railties-4.2.2/lib/rails/rack/logger.rb:20:in `block in call'
vendor/bundle/gems/activesupport-4.2.2/lib/active_support/tagged_logging.rb:68:in `block in tagged'
vendor/bundle/gems/activesupport-4.2.2/lib/active_support/tagged_logging.rb:26:in `tagged'
vendor/bundle/gems/activesupport-4.2.2/lib/active_support/tagged_logging.rb:68:in `tagged'
vendor/bundle/gems/railties-4.2.2/lib/rails/rack/logger.rb:20:in `call'
vendor/bundle/gems/actionpack-4.2.2/lib/action_dispatch/middleware/request_id.rb:21:in `call'
vendor/bundle/gems/rack-1.6.4/lib/rack/methodoverride.rb:22:in `call'
vendor/bundle/gems/rack-1.6.4/lib/rack/runtime.rb:18:in `call'
vendor/bundle/gems/activesupport-4.2.2/lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
vendor/bundle/gems/actionpack-4.2.2/lib/action_dispatch/middleware/static.rb:113:in `call'
vendor/bundle/gems/rack-1.6.4/lib/rack/sendfile.rb:113:in `call'
vendor/bundle/gems/actionpack-4.2.2/lib/action_dispatch/middleware/ssl.rb:24:in `call'
vendor/bundle/gems/railties-4.2.2/lib/rails/engine.rb:518:in `call'
vendor/bundle/gems/railties-4.2.2/lib/rails/application.rb:164:in `call'
vendor/bundle/gems/puma-3.6.2/lib/puma/configuration.rb:225:in `call'
vendor/bundle/gems/puma-3.6.2/lib/puma/server.rb:578:in `handle_request'
vendor/bundle/gems/puma-3.6.2/lib/puma/server.rb:415:in `process_client'
vendor/bundle/gems/puma-3.6.2/lib/puma/server.rb:275:in `block in run'
vendor/bundle/gems/puma-3.6.2/lib/puma/thread_pool.rb:116:in `call'
vendor/bundle/gems/puma-3.6.2/lib/puma/thread_pool.rb:116:in `block in spawn_thread'

Help.

Could it be that your configuration file is telling EB to skip asset compilation? See docs here: http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_Ruby.container.html#create_deploy_Ruby.env.console.ruby.envprops

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM