gpt4 book ai didi

ruby - Redmine 安装 Apache2 Bundler PermissionError

转载 作者:太空宇宙 更新时间:2023-11-03 16:19:58 24 4
gpt4 key购买 nike

我正在尝试使用这个 tutorial 安装 Redmine :我对 ruby 不熟悉。每当我去 http://localhost/redminehttp://localhost/redmine/settings?tab=general在我的浏览器中,我得到一个包含消息的页面:

We're sorry, but something went wrong.

We've been notified about this issue and we'll take a look at it shortly.

所以我决定查看我的 apache2 错误日志:sudo nano/var/log/apache2/error.log

发现如下信息,将Bundler文件夹权限改为everyone,重启Apache。然而,这并没有帮助我仍然在我的浏览器中收到相同的消息。我做错了什么?

使用 Ubuntu 14.05

/var/log/apache2/error.log

[ 2016-02-05 15:26:39.0461 24027/7fca480e5700 age/Cor/App/Implementation.cpp:304 ]: Could not spawn process for application /usr/share/redmine: An error occurred while starting up the preloader.
Error ID: d4625db4
Error details saved to: /tmp/passenger-error-yGu5Vm.html
Message from application: Bundler::PermissionError (Bundler::PermissionError)
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/shared_helpers.rb:116:in `rescue in filesystem_access'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/shared_helpers.rb:114:in `filesystem_access'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/definition.rb:267:in `lock'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/environment.rb:34:in `lock'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:44:in `setup'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler.rb:92:in `setup'
/var/lib/gems/2.1.0/gems/bundler-1.11.2/lib/bundler/setup.rb:18:in `<top (required)>'
/usr/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
/usr/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:430:in `activate_gem'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:297:in `block in run_load_path_setup_code'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:435:in `running_bundler'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:296:in `run_load_path_setup_code'
/usr/share/passenger/helper-scripts/rack-preloader.rb:100:in `preload_app'
/usr/share/passenger/helper-scripts/rack-preloader.rb:156:in `<module:App>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<main>'


[ 2016-02-05 15:26:39.0552 24027/7fca4aaee700 age/Cor/Con/CheckoutSession.cpp:277 ]: [Client 2-1] Cannot checkout session because a spawning error occurred. The identifier of the error is d4625db4. Please see earlier logs for details about the error.

在/tmp/passenger-error-yGu5Vm.html 中:

Bundler::PermissionError (Bundler::PermissionError)
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/shared_helpers.rb:116:in `rescue in filesystem_access'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/shared_helpers.rb:114:in `filesystem_access'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/definition.rb:267:in `lock'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/environment.rb:34:in `lock'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/runtime.rb:44:in `setup'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler.rb:92:in `setup'
/opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib/bundler/setup.rb:18:in `<top (required)>'
/opt/redmine/.rvm/rubies/ruby-2.1.4/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/opt/redmine/.rvm/rubies/ruby-2.1.4/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:430:in `activate_gem'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:297:in `block in run_load_path_setup_code'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:435:in `running_bundler'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:296:in `run_load_path_setup_code'
/usr/share/passenger/helper-scripts/rack-preloader.rb:100:in `preload_app'
/usr/share/passenger/helper-scripts/rack-preloader.rb:156:in `<module:App>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<main>'

Error ID
5d410186
Application root
/usr/share/redmine
Environment (value of RAILS_ENV, RACK_ENV, WSGI_ENV, NODE_ENV and PASSENGER_APP_ENV)
production
Ruby interpreter command

/usr/bin/passenger_free_ruby

User and groups

uid=119(redmine) gid=128(redmine) groups=128(redmine)

Environment variables

APACHE_PID_FILE = /var/run/apache2/apache2.pid
rvm_bin_path = /opt/redmine/.rvm/bin
GEM_HOME = /opt/redmine/.rvm/gems/ruby-2.1.4
SHELL = /bin/bash
APACHE_RUN_USER = www-data
IRBRC = /opt/redmine/.rvm/rubies/ruby-2.1.4/.irbrc
PASSENGER_DEBUG_DIR = /tmp/passenger.spawn-debug.XXXXVrAXrr
MY_RUBY_HOME = /opt/redmine/.rvm/rubies/ruby-2.1.4
rvm_stored_umask = 0022
USER = redmine
_system_type = Linux
rvm_path = /opt/redmine/.rvm
PASSENGER_USE_FEEDBACK_FD = true
rvm_prefix = /opt/redmine
APACHE_LOG_DIR = /var/log/apache2
PATH = /opt/redmine/.rvm/gems/ruby-2.1.4/bin:/opt/redmine/.rvm/gems/ruby-2.1.4@global/bin:/opt/redmine/.rvm/rubies/ruby-2.1.4/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/redmine/.rvm/bin
QT_QPA_PLATFORMTHEME = appmenu-qt5
rvm_loaded_flag = 1
PWD = /usr/share/redmine
APACHE_RUN_GROUP = www-data
LANG = C
_system_arch = x86_64
_system_version = 14.04
rvm_version = 1.26.11 (latest)
SHLVL = 0
HOME = /opt/redmine
LOGNAME = redmine
SERVER_SOFTWARE = Apache/2.4.7 (Ubuntu) SVN/1.8.8 Phusion_Passenger/5.0.24
GEM_PATH = /opt/redmine/.rvm/gems/ruby-2.1.4:/opt/redmine/.rvm/gems/ruby-2.1.4@global
APACHE_LOCK_DIR = /var/lock/apache2
APACHE_RUN_DIR = /var/run/apache2
RUBY_VERSION = ruby-2.1.4
rvm_user_install_flag = 1
_system_name = Ubuntu
IN_PASSENGER = 1
PYTHONUNBUFFERED = 1
NODE_PATH = /usr/share/passenger/node
RAILS_ENV = production
RACK_ENV = production
WSGI_ENV = production
NODE_ENV = production
PASSENGER_APP_ENV = production
RAILS_RELATIVE_URL_ROOT = /redmine
RACK_BASE_URI = /redmine
PASSENGER_BASE_URI = /redmine
_ORIGINAL_GEM_PATH = /opt/redmine/.rvm/gems/ruby-2.1.4:/opt/redmine/.rvm/gems/ruby-2.1.4@global
BUNDLE_BIN_PATH = /opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/exe/bundle
BUNDLE_GEMFILE = /usr/share/redmine/Gemfile
RUBYOPT = -rbundler/setup
RUBYLIB = /opt/redmine/.rvm/gems/ruby-2.1.4/gems/bundler-1.11.2/lib

最佳答案

FinkAvenue :当您的 ruby​​ 的 gems 路径没有适当的权限时,就会发生这种情况。在这种情况下,请确保 /opt/redmine/.rvm/gems/ruby-2.1.4/gems 具有适当的权限。运行 Bundler 的用户无权访问目录 /选择/redmine/.rvm/gems/ruby-2.1.4/gems

关于ruby - Redmine 安装 Apache2 Bundler PermissionError,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35226981/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com