安装 ruby​​gems 时出错 rails

rubygems error installing rails

尝试在我的亚马逊实例上安装 ruby gems 时出现此错误。谁能解释一下?

ubuntu@ip-myinstance:~$ sudo apt-get install rubygems

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package rubygems is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  ruby

E: Package 'rubygems' has no installation candidate

我没看懂那条消息。我是按照 http://www.frontcoded.com/rails-on-amazon-ec2-ubuntu.html 的指示去做的。我也试过

which rubygems

结果是一片空白。如果可能的话,我想取消这个问题以停止投反对票。谢谢。

您正在尝试安装错误的包。在现代 Ruby 中,rubygems 是其中的一部分。你收到的消息也是这么说的。

即使服务器端出现问题,无法通过apt-get下载东西与rubygems站点是否关闭无关。

您收到的消息,为您提供了替代建议,表明相关站点 (apt-get) 未关闭。

您可以使用 this 等服务查看某些网站的状态。