捆绑安装不能脱机工作

我遇到了这个问题。 我认为安装了捆绑器。 而且因为我无法在RoR中创建应用程序时捆绑安装,或者直接在项目中捆绑安装。 如果您有任何问题,请帮助我,并找到解决方案。

enter code here :run bundle install :Fetching gem metadata from https://rubygems.org/. :Error Bundler::HTTPError during request to dependency API :Fetching full source index from https://rubygems.org/ :Could not reach https://rubygems.org/ 

如果安装了gem,则可以使用bundle install --local 。 它不需要互联网连接

以下方法适用于我。

 $ rails new blog -B # -B tells rails not to run bundle install cd blog $ bundle install --local Edit the GemFile and uncomment the line "therubyracer" $ rails server => Booting WEBrick => Rails 4.0.0 application starting in development on http://0.0.0.0:3000 => Run `rails server -h` for more startup options => Ctrl-C to shutdown server [2013-09-28 19:09:35] INFO WEBrick 1.3.1 [2013-09-28 19:09:35] INFO ruby 2.0.0 (2013-05-14) [i686-linux] [2013-09-28 19:09:35] INFO WEBrick::HTTPServer#start: pid=1635 port=3000 

您需要联机以便捆绑者可以使用rubygems检查您是否拥有最新的gem并在必要时下载它们。