Hi, all
一直在社区看帖,最近才想到要注册,也和大家问声好。
某是 ruby 新手一枚...
于是这几天想在公司内部搭建一个 rubygems 的镜像,用于生产环境(因为不允许访问公网)
参考了这张帖子 http://ruby-china.org/topics/264
某的环境是gentoo linux
/ rvm 1.12.3 (stable)
/ ruby 1.9.2p318
按照说明,把rubygems-mirror
clone 下来后bundle install
cat ~/.gem/.mirrorrc
的设置,某是从淘宝的镜像同步的
cat ~/.gem/.mirrorrc --- - from: http://ruby.taobao.org to: /var/www/rubygems parallelism: 5
以下是问题
在运行rake mirror:update
的时候,遇到下面的错误(虽然不影响同步),这里的dot
找不到是什么原因
# rake mirror:update
** README.rdoc is missing or in the wrong format for auto-intuiting.
run sow blah
and look at its text files
which: no dot in (/home/aleiphoenix/.rvm/gems/ruby-1.9.2-p318/bin:/home/aleiphoenix/.rvm/gems/ruby-1.9.2-p318@global/bin:/home/aleiphoenix/.rvm/rubies/ruby-1.9.2-p318/bin:/home/aleiphoenix/.rvm/bin:/home/aleiphoenix/.pythonbrew/bin:/home/aleiphoenix/.pythonbrew/pythons/Python-2.7.2/bin:/home/aleiphoenix/.rvm/bin:/home/aleiphoenix/.rvm/gems/ruby-1.9.2-p318/bin:/home/aleiphoenix/.rvm/gems/ruby-1.9.2-p318@global/bin:/home/aleiphoenix/.rvm/rubies/ruby-1.9.2-p318/bin:/usr/local/bin:/usr/bin:/bin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.5.3:/home/aleiphoenix/bin)
Fetching: http://gems.rubyforge.org/specs.4.8.gz with 5 threads
同步好之后,使用 geminabox 设置服务端,运行 OK,客户端设置了gem sources
后,尝试安装会报错
# gem install --verbose rails GET http://localhost:9292/latest_specs.4.8.gz 404 Not Found WARNING: Error fetching data: bad response Not Found 404 (http://localhost:9292/latest_specs.4.8.gz) GET http://localhost:9292/quick/Marshal.4.8/rails-3.2.3.gemspec.rz 404 Not Found Error fetching remote data: bad response Not Found 404 (http://localhost:9292/quick/Marshal.4.8/rails-3.2.3.gemspec.rz) Falling back to local-only install ERROR: Could not find a valid gem 'rails' (>= 0) in any repository ERROR: Possible alternatives: rails
服务端的信息
# rackup [2012-05-06 11:50:17] INFO WEBrick 1.3.1 [2012-05-06 11:50:17] INFO ruby 1.9.2 (2012-02-14) [x86_64-linux] [2012-05-06 11:50:17] INFO WEBrick::HTTPServer#start: pid=15330 port=9292 127.0.0.1 - - [06/May/2012 11:50:27] "GET /latest_specs.4.8.gz HTTP/1.1" 404 - 0.0051 127.0.0.1 - - [06/May/2012 11:50:27] "GET /quick/Marshal.4.8/rails-3.2.3.gemspec.rz HTTP/1.1" 404 - 0.0006
请问一下这 2 个问题该如何解决?
谢谢