Install Node.js via NodeSource

Install a specific Node major version from the official NodeSource APT repo.

Adds NodeSource's apt repository for a specific Node.js LTS version and installs it. This gives a more current version than Ubuntu's default apt, which is often several major versions behind.

When you need this: When deploying a Node.js application or when npm tooling (Vite, webpack) requires a specific Node version.

Variables

Command


        
2 views 0 copies
Log in to rate
Log in to save

Free account — save snippets into your own collections.