回形针gem欺骗错误?

我正在使用CentOS。 我有paperclip gem最新版本。 我读过有关欺骗的内容,但问题仍然存在! 我甚至尝试使用旧版本3.5.2并仍然出错。 我在远程服务器上这样做! 不知道我是否必须重启apache或者什么? Heelp!

I, [2014-04-09T18:41:45.251093 #5841] INFO -- : Command :: file -b --mime-type '/tmp/5b42e9da0503617fea7f216d7860262920140409-5841-k6wzm6' I, [2014-04-09T18:41:45.257581 #5841] INFO -- : [paperclip] Content Type Spoof: Filename justdoit.jpeg (["image/jpeg"]), content type discovered from file command: . See documentation to allow this combination. 

添加选项后,现在我得到了这个:

 I, [2014-04-09T21:20:46.797630 #11118] INFO -- : Started GET "/system/bboys/avatars/000/000/001/medium/Casper_Family_11.jpg?1397064045" for 90.197.101.127 at 2014-04-09 21:20:46 +0400 F, [2014-04-09T21:20:46.799580 #11118] FATAL -- : ActionController::RoutingError (No route matches [GET] "/system/bboys/avatars/000/000/001/medium/Casper_Family_11.jpg"): vendor/bundle/ruby/2.0.0/gems/actionpack-4.0.0/lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call' 

如果您不担心jpeg / jpg文件的欺骗检查,可以设置Paperclip选项:

 Paperclip.options[:content_type_mappings] = { jpeg: 'image/jpeg', jpg: 'image/jpeg' } 

这将绕过file -b --mime-type命令。

我的问题是我没有安装ImageMagic ,这是回形针的工作要求。