使用命令安装nodejs
Run on RHEL, CentOS, CloudLinux, Amazon Linux or Fedora:
Node.js v17.x
# As root
curl -fsSL https://rpm.nodesource.com/setup_17.x | bash -
# No root privileges
curl -fsSL https://rpm.nodesource.com/setup_17.x | sudo bash -
Node.js v16.x
# As root
curl -fsSL https://rpm.nodesource.com/setup_16.x | bash -
# No root privileges
curl -fsSL https://rpm.nodesource.com/setup_16.x | sudo bash -