您的位置:首页 > Web前端 > Node.js

ubuntu下安装nodejs

2016-06-27 10:49 573 查看

NodeJS安装

Complete installation instructions have since been uploaded here by Nodesource. It is copied below for your reference. Instructions are the same for updating to the latest version.

Node.js v5.x:

NOTE: If you are using Ubuntu Precise or Debian Wheezy, you might want to read about running Node.js >= 4.x on older distros.

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash - sudo apt-get install -y nodejs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_5.x | bash - apt-get install -y nodejs


Node.js v4.x:

NOTE: If you are using Ubuntu Precise or Debian Wheezy, you might want to read about running Node.js >= 4.x on older distros.

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash - sudo apt-get install -y nodejs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_4.x | bash - apt-get install -y nodejs


Node.js v0.12:

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_0.12 | sudo -E bash - sudo apt-get install -y nodejs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_0.12 | bash - apt-get install -y nodejs


Node.js v0.10:

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_0.10 | sudo -E bash - sudo apt-get install -y nodejs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_0.10 | bash - apt-get install -y nodejs


io.js v3.x:

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_iojs_3.x | sudo -E bash - sudo apt-get install -y iojs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_iojs_3.x | bash - apt-get install -y iojs


io.js v2.x:

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_iojs_2.x | sudo -E bash - sudo apt-get install -y iojs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_iojs_2.x | bash - apt-get install -y iojs


io.js v1.x:

Note: this branch of io.js is not actively maintained and is not recommended for production use.

# Using Ubuntu curl -sL https://deb.nodesource.com/setup_iojs_1.x | sudo -E bash - sudo apt-get install -y iojs # Using Debian, as root curl -sL https://deb.nodesource.com/setup_iojs_1.x | bash - apt-get install -y iojs


来源

https://github.com/nodesource/distributions#installation-instructions
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  ubuntu nodejs