GoAdmio Command Line: nginx with /go/nginx

/go/nginx has two modes: The reverse of the first mode is apache. Every admin action in GoAdmio has a matching /go/ command, so anything you can click you can also script.

Quick start

# Rebuild the Nginx virtual host of one domain
/go/nginx example.com
/go/reload

Arguments

Position Name Required Notes
1 <domain> No A hosted domain. /home/<domain> must exist. Without it, the server is converted to Nginx.

The command has no --option flags.

Examples

# Rebuild one domain, then apply it
/go/nginx example.com
/go/reload

# Check the configuration before reloading
nginx -t

# Switch the whole server from Apache to Nginx (the server reboots)
/go/nginx

# Look at the generated file
cat /etc/nginx/vhost/example.com.conf

Output

Message Meaning
Switching from Apache to NGINX... Server conversion has started.
NGINX: Domain Directory /home/<domain> not exists. Domain mode: the account folder does not exist. Nothing was written.
File /etc/letsencrypt/options-ssl-nginx.conf not exists. Please wait... Domain mode: the Let’s Encrypt Nginx settings file is missing, and the command is trying to copy it. See SSL requirements.

Domain mode prints nothing else. Every call is also appended to /var/log/go/nginx.log.

Exit codes

Situation Exit code
Server conversion Always 1
Domain folder missing 1
Domain virtual host written 0

See the full reference at /go/nginx 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 *