centos安裝node

徐小禹_web發表於2024-07-12

下載:wget https://nodejs.org/dist/v14.15.4/node-v14.15.4-linux-x64.tar.xz

解壓:

tar -xvf node-v14.15.4-linux-x64.tar.xz
mkdir -p /usr/local/nodejs
mv node-v14.15.4-linux-x64/* /usr/local/nodejs/

軟連結

ln -s /usr/local/nodejs/bin/node /usr/local/bin

ln -s /usr/local/nodejs/bin/npm /usr/local/bin

淘寶映象:

npm config set registry https://registry.npm.taobao.org


npm config list

相關文章