If you read my previous blog post, you know I've been experimenting with CDNs & VPS Servers. This time, I wanted to use Node.js on the Hostinger's hosting.
Yeah, the same Cloud Global Plan, but as all the support exec. guys say, you cannot normally use Node.js on a server that does not give you root access. So here's a complete info. about how I installed Node.js on the Cloud Global plan which was not a VPS Server.
Pre-requisites => SSH Access in you cPanel / hPanel.
Enable the SSH Access in the panel & copy the ssh command (should be like: ssh -p PORT userId@IpAddress
)
Alrighty then, let's go.
Open terminal & paste SSH command.
Use command
cd ~
Type below command and hit Enter -
shellwget -qO- https://cdn.rawgit.com/creationix/nvm/master/install.sh | bash
Then type the command -
shellexport NVM_DIR="$HOME/.nvm" [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"
Then install
node
vianvm
-shellnvm install node nvm use node
The above steps should show this output -
In the next blog post,
I'll show a working example of running a Node.js Express App on the same server.