For cPanel & WHM version 58
/usr/local/cpanel/scripts/proxydomains script allows you to create the DNS records for a cPanel or Webmail account from the command line.
This script adds the required subdomains to the main domain's DNS record, but does not create a VirtualHost entry in the
For more information, read our Tweak Settings - Domains documentation.
To run the
/usr/local/cpanel/scripts/proxydomains script from the command line as the
root user, use the following format:
You can use either of the following actions:
|Create a proxy subdomain.|
|Remove a proxy subdomain.|
The following table lists the options that you can pass with this script:
The cPanel user's domains to configure.
If you do not specify a user, this script attempts to configure the proxy subdomains for all of the server's cPanel accounts.
The domain that you wish to configure.
If you do not specify a domain, this script attempts to configure the proxy subdomains for all of the server's cPanel accounts.
The proxy subdomain that you wish to configure.
If you do not specify a subdomain, the script adds or removes the following subdomains:
The Autodiscover host that you previously configured.
Whether the script should function as if Autodiscover support is not disabled, even if it is disabled.
For example, to add the proxy subdomain
webdisk.example.com for the cPanel user
john, run the following command:
The output resembles the following example:
The options that you pass to the command determine its output.