我有一个使用 web-app-theme gem 的基于 Rails 3.2.6 的应用程序。在生产中部署后,我在/var/log/apache2/error.log
.
[Wed Jul 18 23:00:14 2012] [error] [client 50.53.58.188] Premature end of script headers: fonts, referer: https://xxx.xxx.xx.xxx
[ pid=8920 thr=139857209571072 file=ext/apache2/Hooks.cpp:819 time=2012-07-18 23:00:14.743 ]: The backend application (process 9474) did not send a valid HTTP response; instead, it sent nothing at all. It is possible that it has crashed; please check whether there are crashing bugs in this application.
[ pid=9474 thr=9488700 file=utils.rb:176 time=2012-07-18 23:00:14.744 ]: *** Exception ActionController::RoutingError in application (No route matches [GET] "/assets/fonts/museosans_500-webfont.svg") (process 9474, thread #<Thread:0x00000001219278>):
from /usr/lib/ruby/gems/1.9.1/gems/actionpack-3.1.3/lib/action_dispatch/middleware/show_exceptions.rb:53:in `call'
from /usr/lib/ruby/gems/1.9.1/gems/railties-3.1.3/lib/rails/rack/logger.rb:13:in `call'
from /usr/lib/ruby/gems/1.9.1/gems/rack-1.3.6/lib/rack/methodoverride.rb:24:in `call'
from /usr/lib/ruby/gems/1.9.1/gems/rack-1.3.6/lib/rack/runtime.rb:17:in `call'
from /usr/lib/ruby/gems/1.9.1/gems/activesupport-3.1.3/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
.....
我已将提到的文件museosans_500-webfont.svg
放在app/assets/fonts/
目录中。但是为什么我还是这个错误。对于其他资产,我也看到类似的错误,例如/assets/fonts/museosans_500-webfont.ttf
等。
非常感谢任何反馈。谢谢。
——阿塔朗普