Last active
September 5, 2021 20:06
-
-
Save jaxtheking/9f4deaf4bb4d21660f061a52d6d717f0 to your computer and use it in GitHub Desktop.
Installing Node.js on a cPanel/WHM Server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Check if nodesources need removing | |
rpm -qa 'node|npm' | |
## Remove nodejs installed via yum | |
yum remove nodesource-release* nodejs | |
yum clean all | |
## Install node.js using compiled binaries | |
cd ~ | |
wget https://nodejs.org/dist/v14.9.0/node-v14.9.0-linux-x64.tar.xz | |
sudo tar --strip-components 1 -xJvf node-v* -C /usr/local | |
node --version | |
# fix ownerships in /usr/local folders with chown -R root:root . |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment