2

我在使用 Ruby 1.9.3p327、RubyGems 1.8.23 和Passenger 3 的AWS Micro 实例上。

我的服务器(当我没有尝试修复问题时)位于http://shaanan.cohney.info/gitlab/

我正在尝试将 Gitlab 安装到 Apache2 上。

这一切都顺利到我尝试通过乘客部署安装的地步。

我得到错误:

Could not find multi_json-1.5.0 in any of the sources (Bundler::GemNotFound)

/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.3.0/lib/bundler/spec_set.rb   95  in `block in materialize'

我打印的加载路径是:

["/usr/local/lib/ruby/gems/1.9.1/gems/passenger-3.0.19/lib", "/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.3.0/lib", "/usr/local/lib/ruby/site_ruby/1.9.1", "/usr/local/lib/ruby/site_ruby/1.9.1/x86_64-linux", "/usr/local/lib/ruby/site_ruby", "/usr/local/lib/ruby/vendor_ruby/1.9.1", "/usr/local/lib/ruby/vendor_ruby/1.9.1/x86_64-linux", "/usr/local/lib/ruby/vendor_ruby", "/usr/local/lib/ruby/1.9.1", "/usr/local/lib/ruby/1.9.1/x86_64-linux"]

缺少安装我的 gem 的目录。

我在网上搜索过,但在尝试了多种方法后还没有找到解决办法。

当我访问 myhostname.com/gitlab 时出现错误

我目前的猜测是,这与我为其安装 ruby​​ 的用户、应用程序的用户以及用户乘客的运行身份有关。

更新:我已经升级到乘客的测试版,看看它是否会有所作为。出错时,它给我的环境如下:

APACHE_PID_FILE = /var/run/apache2.pid
SHELL = /bin/bash
APACHE_RUN_USER = www-data
PASSENGER_DEBUG_DIR = /tmp/passenger.spawn-debug.27672-140235446962704
USER = gitlab
APACHE_LOG_DIR = /var/log/apache2
PATH = /usr/local/bin:/usr/bin:/bin
PWD = /home/gitlab/gitlab
APACHE_RUN_GROUP = www-data
LANG = C
SHLVL = 0
HOME = /home/gitlab
LOGNAME = gitlab
APACHE_LOCK_DIR = /var/lock/apache2
APACHE_RUN_DIR = /var/run/apache2
IN_PASSENGER = 1
PYTHONUNBUFFERED = 1
RAILS_ENV = production
RACK_ENV = production
WSGI_ENV = production
PASSENGER_ENV = production
RAILS_RELATIVE_URL_ROOT = production
RACK_BASE_URI = production
PASSENGER_BASE_URI = production
REQUEST_METHOD = GET
SERVER_PORT = 80
SERVER_ADDR = 10.244.35.233
QUERY_STRING = 
SERVER_PROTOCOL = HTTP/1.1
REMOTE_PORT = 4789
REMOTE_ADDR = 72.13.132.134
REQUEST_URI = /gitlab/
SERVER_SOFTWARE = Apache/2.2.22 (Ubuntu)
DOCUMENT_ROOT = /var/www/
SERVER_NAME = shaanan.cohney.info
GEM_PATH = 
SERVER_ADMIN = webmaster@localhost
BUNDLE_GEMFILE = /home/gitlab/gitlab/Gemfile
_ORIGINAL_GEM_PATH = /home/ubuntu/.rvm/gems/ruby-1.9.3-p392
GEM_HOME = /home/gitlab/gitlab/vendor/bundle/ruby/1.9.1

我还注意到 _ORIGINAL_GEM_PATH 设置为我安装时的 RVM 值。

4

0 回答 0