運行 Ghost 必須要安裝 Node.js。但是 Ubuntu 或 Debian 的軟件倉庫中的 Node.js 更新較慢,甚至只能等到新版本發布才能有最新的 Node.js 用。下面我們說一下從 NodeSource 提供的倉庫中安裝最新版本的 Node.js。
被支持的 Ubuntu 版本:
被支持的 Debian 版本:
Ghost 目前支持 0.10.*
、0.12.*
和 >=4.2 <5.* (LTS)
版本的 Node.js,推薦的是 >0.10.40 (最新版本)
。詳細說明請看這裡:http://support.ghost.org/supported-node-versions/
根據我們的安裝經驗,推薦安裝 4.x(LTS)版本的 Node.js。
Ubuntu 系統
curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash -
sudo apt-get install -y nodejs
Debian 系統。以 root 權限執行下列指令
curl -sL https://deb.nodesource.com/setup_4.x | bash -
apt-get install -y nodejs
Ubuntu 系統
curl -sL https://deb.nodesource.com/setup_0.10 | sudo -E bash -
sudo apt-get install -y nodejs
Debian 系統。以 root 權限執行下列指令
curl -sL https://deb.nodesource.com/setup_0.10 | bash -
apt-get install -y nodejs
Ubuntu 系統
curl -sL https://deb.nodesource.com/setup_0.12 | sudo -E bash -
sudo apt-get install -y nodejs
Debian 系統。以 root 權限執行下列指令
curl -sL https://deb.nodesource.com/setup_0.12 | bash -
apt-get install -y nodejs
注意:v5.x 的 Node.js 不被 Ghost 支持,以下安裝介紹只為了完整介紹 Node.js 各個版本的安裝!
Ubuntu 系統
curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash -
sudo apt-get install -y nodejs
Debian 系統。以 root 權限執行下列指令
curl -sL https://deb.nodesource.com/setup_5.x | bash -
apt-get install -y nodejs
下面關於Node.js的內容你可能也喜歡:
在 Ubuntu 14.04/15.04 上安裝配置 Node.js v4.0.0 http://www.linuxidc.com/Linux/2015-10/123951.htm
如何在CentOS 7安裝Node.js http://www.linuxidc.com/Linux/2015-02/113554.htm
Ubuntu 14.04下搭建Node.js開發環境 http://www.linuxidc.com/Linux/2014-12/110983.htm
Ubunru 12.04 下Node.js開發環境的安裝配置 http://www.linuxidc.com/Linux/2014-05/101418.htm
Node.Js入門[PDF+相關代碼] http://www.linuxidc.com/Linux/2013-06/85462.htm
Node.js開發指南 高清PDF中文版 +源碼 http://www.linuxidc.com/Linux/2014-09/106494.htm
Node.js入門開發指南中文版 http://www.linuxidc.com/Linux/2012-11/73363.htm
Ubuntu 編譯安裝Node.js http://www.linuxidc.com/Linux/2013-10/91321.htm
Node.js 的詳細介紹:請點這裡
Node.js 的下載地址:請點這裡