Ubuntu 16.10無法安裝Nodejs?還有其他選擇嗎?

Ubuntu 16.10無法安裝Nodejs?還有其他選擇嗎?

我目前正在嘗試在我的系統上安裝nodejs,以便使用MSI的LED管理器gui,但是當我使用nodejs的官方文件來了解如何安裝時,我得到了404未在列表中找到。

我在終端機中使用的命令:

curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -
sudo apt-get install -y nodejs

這些是我收到的錯誤:

W: The repository 'http://ppa.launchpad.net/shawn-p-huang/ppa/ubuntu yakkety Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://ppa.launchpad.net/shawn-p-huang/ppa/ubuntu/dists/yakkety/main/binary-i386/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
Error executing command, exiting

我知道 Ubuntu 16.10 有點新,但我必須從 16.4 切換到 16.10,因為它給我帶來了很多問題,直到我升級到 16.10 才得以解決。

目前是否有任何修復或替代方法來安裝 Nodejs 版本 6 或更高版本?

謝謝

答案1

首先新增儲存庫密鑰

curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - 

然後設置存儲庫並安裝節點7.3.0

sudo sh -c "echo deb https://deb.nodesource.com/node_7.x yakkety main \ > /etc/apt/sources.list.d/nodesource.list"
sudo apt-get update && sudo apt-get install nodejs

相關內容