/go/nodejs installs Node.js on a GoAdmio server, together with the tools GoAdmio needs alongside it. It: It works on CentOS, AlmaLinux, Rocky Linux, Red Hat, Fedora, Debian, and Ubuntu. The command runs sudo internally, so run it as root or as a user with sudo rights. Every admin action in GoAdmio has a matching /go/ command, so anything you can click you can also script.
Quick start
# Install Node.js 22 (the default)
/go/nodejs
Options
The command has one optional argument and no -- options.
| Argument | Required | Default | Notes |
|---|---|---|---|
version |
No | 22 |
A Node.js major version number, such as 18, 20, or 22. It is not checked before use. |
[!NOTE]
On Debian and Ubuntu the repository setup step uses NodeSource’s RPM address (rpm.nodesource.com), which is meant for RPM-based systems. The version you pass may therefore not be honored there, andaptmay install whatever Node.js version the system provides. Runnode -vafterward to confirm what you got.
Examples
# Install the default version (22)
/go/nodejs
# Install Node.js 20
/go/nodejs 20
# Check the installed versions
node -v
npm -v
# Check the OS value the command will use
cat /usr/local/goadmio/linux/os.db
# See recent runs of the command
tail /var/log/go/nodejs.log
Output
The command prints no summary of its own. You see the output of the NodeSource setup script and of the package manager as it runs.
| Outcome | What you get |
|---|---|
| Supported operating system | Package manager output, ending with the npm install -g mudslide result. |
| Unsupported operating system | Unknown operating system. and exit status 1. Nothing is installed. |
The script does not stop when a step fails. Later steps still run, and the exit status is that of the last command (npm install -g mudslide). Check the output for errors, then run node -v to confirm the install.
Log
Each run appends one line to /var/log/go/nodejs.log:
[Nov 21 12:00:00]# nodejs 20
See the full reference at /go/nodejs and the GoAdmio command index.
GoAdmio is free and open source, with no license fees and no account limits. Read the GoAdmio docs, or see why it is a free cPanel alternative at goadmio.com.
