SocketError (getaddrinfo: Name or service not known) - Sunspot/Solr Rails development

前端 未结 7 922
轮回少年
轮回少年 2020-12-15 07:15

I have had lots of trouble with deploying my rails 3.0.10 application to Ubuntu 10.04 server with Passenger, Capistrano, nginx and MySQL (and even more trouble with apache2)

7条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-15 08:00

    I added this line to the top of file app/controllers/search_controller.rb

    require 'resolv-replace'
    

    Or alternatively you can put it to initializers/requires.rb

提交回复
热议问题