GoAdmio Command Line: admin with /go/admin

/go/admin manages the admin user. The admin user is the account you log in to the GoAdmio panel with, so you do not have to use the root password. The command does one of two things, depending on its argument: Every admin action in GoAdmio has a matching /go/ command, so anything you can click you can also script.

Quick start

# Set a new password for the admin user (run as root)
/go/admin 'N3wP@ssw0rd'

Arguments

Argument Mode What it does
A valid IPv4 address, such as 203.0.113.45 Alert mode Sends the login alert. The password is not changed.
Anything else Password mode Uses the value as the new admin password.

An argument that looks like an IPv4 address is always treated as an address. A password such as 10.20.30.40 therefore sends an alert and changes nothing.

Quote passwords that contain special characters or spaces, for example with single quotes. Avoid spaces on Debian and Ubuntu.

Examples

# Set the admin user's password
/go/admin 'N3wP@ssw0rd'

# Send a login alert for an address (a test of the alert)
/go/admin 203.0.113.45

# Change the password without putting it on the command line
passwd admin

# Review the log of past runs (arguments are hidden)
tail -n 20 /var/log/go/admin.log

Output

Password mode

On AlmaLinux, Rocky, CentOS, Red Hat, and Fedora, passwd prints its usual status messages:

Changing password for user admin.
passwd: all authentication tokens updated successfully.

On Debian and Ubuntu, nothing is printed when the change works.

Alert mode

Nothing is printed. The email and WhatsApp message are sent with /go/sendmail and /go/sendwhatsapp.

Item Value
Subject Admin Login Alerts
Message User root just logged in from <IP> (<city> - <country>)

The message always says root, whatever the argument is.

See the full reference at /go/admin 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.

By:

Posted in:


Leave a Reply

Your email address will not be published. Required fields are marked *