简体   繁体   English

安装雪貂和acts_as_ferret

[英]Installing ferret and acts_as_ferret

I'm looking for a solid walkthrough or some direction on getting ferret set up on my rails server. 我正在寻找可靠的演练或在我的Rails服务器上设置雪貂的方向。 Everyone on the internet makes it seem so easy, but I can't seem to get it all together. 互联网上的每个人都使它看起来如此简单,但我似乎无法将它们融合在一起。

What I've done succesfully: 我成功完成的工作:

gem install ferret
gem install acts_as_ferret

No sweat. 没汗 No errors. 没有错误。

What doesn't work: 什么不起作用:

Video.find_by_content('test')
-----No Method Error

or ActsAsFerret.find('test', 'my_index') 或ActsAsFerret.find('test','my_index')

I get console to recognize the constant "ActsAsFerret"(only when I install the plugin from https://github.com/jkraemer/acts_as_ferret ), but find() returns a No Method Error. 我得到控制台来识别常量“ ActsAsFerret”(仅当我从https://github.com/jkraemer/acts_as_ferret安装插件时),但是find()返回No Method Error。 Update: Installing the plugin like this also prevents Mongrel from starting 更新:像这样安装插件也会阻止Mongrel启动

I AM running in development mode, but configured ferret_server.yml to know what's up. 我正在开发模式下运行,但是配置了ferret_server.yml以了解最新情况。

So does any one have any suggestions? 那么有人有什么建议吗? And has anyone had more luck using acts_as_ferret as a gem or as a plugin? 有人将acts_as_ferret作为gem或plugin运气更好吗? Googling gets me small scraps and parts of tutorials that don't seem to fit together, so I hereby vow to blog a solution to this when I figure it out. Google搜寻使我得到了一些看起来不太合适的小片段和教程的一部分,因此我发誓要在解决这个问题时写一个解决方案。

ruby 1.8.7 (2010-01-10 patchlevel 249) [i486-linux] 红宝石1.8.7(2010-01-10补丁程序级别249)[i486-linux]

rails (3.0.3) 导轨(3.0.3)

PS I also ran PS我也跑了

sudo apt-get install ferret

on someone's suggestion... still no luck. 根据某人的建议...仍然没有运气。 I'm not even sure if that'd be a reasonable solution for deploying. 我什至不确定这是否是部署的合理解决方案。

您可以使用find_with_ferret方法

have you added 你加了吗

gem 'ferret'
gem 'acts_as_ferret'

in your Gemfile and run 在您的Gemfile中并运行

bundle install

?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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