- 12curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -sudo apt-get install -y nodejs
Optional: install build tools
To compile and install native addons from npm you may also need to install build tools:1sudo apt-get install -y build-essential
sudo apt-get install -y nodejs
Automatic yes to prompts. Assume “yes” as answer to all prompts and run non-interactively. If an undesirable situation, such as changing a held package or removing an essential package, occurs then apt-get will abort.
The build-essentials is a reference for all the packages needed to compile a debian package. It generally includes the gcc/g++ compilers an libraries and some other utils. Check the documentation: Here!