返回列表

CentOS下安装NodeJS

默认分类 2014/09/09 04:15

安装Nodejs:
http://www.myhack58.com/Article/sort099/sort0102/2012/33099.htm

    1  yum update
    2  mkdir web
    3  mkdir tmp
    4  cd tmp/
    5  wget http://nodejs.org/dist/v0.10.31/node-v0.10.31.tar.gz
    6  tar -zxvf node-v0.10.31.tar.gz 
    7  cd node-v0.10.31
    8  ls
    9  ./configure 
   10  yum install gcc-c++
   11  ./configure 
   12  make
   13  make install
   14  node -v
   15  npm -v
   16  yun update
   17  yum update
   18  yum install lrzsz
   19  cd ..
   20  rm node node-v0.10.31 -rf
   21  rm node-v0.10.31.tar.gz 
   22  ls
   23  node -v
   24  ls
   25  rz
   26  ls
   27  cp server.js  aa.txt
   28  yum install vim
   29  vim aa.txt 
   30  node server.js 
   31  history

    1  wget http://104.156.226.58:8888/
    2  ls
    3  vim index.html 
    4  vim /etc/sysconfig/iptables
    5  service iptables restart
    6  vim /etc/sysconfig/iptables
    7  service iptables restart
    8  iptables -L
    9  yum update
   10  mkdir web
   11  mkdir tmp
   12  cd tmp/
   13  wget http://nodejs.org/dist/v0.10.31/node-v0.10.31.tar.gz
   14  tar -zxvf node-v0.10.31.tar.gz 
   15  cd node-v0.10.31
   16  ls
   17  ./configure 
   18  yum install gcc-c++
   19  ./configure 
   20  make
   21  make install
   22  node -v
   23  npm -v
   24  yun update
   25  yum update
   26  yum install lrzsz
   27  cd ..
   28  rm node node-v0.10.31 -rf
   29  rm node-v0.10.31.tar.gz 
   30  ls
   31  node -v
   32  ls
   33  rz
   34  ls
   35  cp server.js  aa.txt
   36  yum install vim
   37  vim aa.txt 
   38  node server.js 
   39  history