加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

如何在debian lenny上安装ruby 1.9.2?

发布时间:2020-12-16 20:36:29 所属栏目:百科 来源:网络整理
导读:我想在我的debian lenny服务器上安装最新的ruby和rails. 我发现包http://packages.debian.org/lenny-backports/ruby1.9.1-full,但是当我尝试安装它,我只是得到: atlas:~# apt-get install ruby1.9.1-fullReading package lists... DoneBuilding dependency
我想在我的debian lenny服务器上安装最新的ruby和rails.

我发现包http://packages.debian.org/lenny-backports/ruby1.9.1-full,但是当我尝试安装它,我只是得到:

atlas:~# apt-get install ruby1.9.1-full
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Couldn't find package ruby1.9.1-full

我的sources.list如下所示:

atlas:~# cat /etc/apt/sources.list

deb http://ftp.se.debian.org/debian/ lenny main non-free contrib
deb-src http://ftp.se.debian.org/debian/ lenny main non-free contrib

deb http://security.debian.org/ lenny/updates main contrib non-free
deb-src http://security.debian.org/ lenny/updates main contrib non-free

deb http://volatile.debian.org/debian-volatile lenny/volatile main contrib non-free
deb-src http://volatile.debian.org/debian-volatile lenny/volatile main contrib non-free

我要做什么来安装它?

解决方法

停止.回去.安装Ruby Debian的任何版本,大概是1.8.7或1.8.7.然后安装RVM.我有一些 using RVM with Ubuntu的方向(对不起,不是Debian,但是很接近).严重的是,RVM使得安装任何版本的Ruby很容易.然后,使用RVM安装Ruby 1.9.2,你不需要1.9.1.

这将根据您想要使用Ruby的方式工作.为了开发目的,使用RVM的工作真的很好.对于服务器目的,我想可以使用它,但是您可能会遇到一些问题.我认为RVM为您提供了一些可用于使用init脚本和cron作业运行Ruby脚本的脚本.

或者,您可以从源安装.这不是很难,而不是debian的方式,但它会完成这项工作.这可能更适合安装一些第三方软件包,您可能不知道在编译期间做了什么,以及如何在安全漏洞的情况下获得快速更新.使用RVM或从源手动安装,您可以随时更新.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读