How to enable SSL for Hostname in cPanel
cPanel itself is programmed to check SSL every night for the domains defined in it, including Hostname, but it is necessary to check the Allow AutoSSL to replace invalid or expiring non-AutoSSL certificates option located in the SSL/TLS > Manage Auto SSL section. > Options is activated.
If for any reason this option is not activated or if you intend to install SSL for Hostname before night time, just run the following command through SSH with the root user:
/usr/local/cpanel/bin/checkallsslcerts
The above command will automatically install SSL for Hostname. In addition, the cPanel and WHM login section is secured using the same SSL so that cPanel/WHM login can be accessed without warning.