Rails -Sunspot Solr没有开始开发



当我执行以下命令时,bundle solr相关的宝石

捆绑式耙子黑子:solr:start

我有权限错误:

Creating directory /apps/test_app/current/solr
rake aborted!
Errno::EACCES: Permission denied @ dir_s_mkdir - /apps
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/installer.rb:48:in `block in execute'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/installer.rb:37:in `each'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/installer.rb:37:in `execute'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/installer.rb:17:in `execute'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/server.rb:174:in `install_solr_home'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/server.rb:40:in `bootstrap'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/server.rb:55:in `start'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/sunspot_solr-2.2.6/lib/sunspot/solr/tasks.rb:10:in `block (3 levels) in <top (required)>'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/gems/rake-11.3.0/exe/rake:27:in `<top (required)>'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/bin/ruby_executable_hooks:15:in `eval'
/home/rp/.rvm/gems/ruby-2.3.1@test_app/bin/ruby_executable_hooks:15:in `<main>'
Tasks: TOP => sunspot:solr:start
(See full trace by running task with --trace)

如果有人对此有所了解,将会有很大的帮助。预先感谢!

sunspot配置应该是此config/sunspot.yml

development:
  solr:
    hostname: localhost
    port: 8982
    log_level: INFO
test:
  solr:
    hostname: localhost
    port: 8981
    log_level: WARNING

参考:github repo

最新更新