Remove AutoSSL Excluded Domains from Command Line

This article provides a guide demonstrating the process to remove AutoSSL excluded domains from the command line. This guide is intended for root-level administrators of cPanel VPS and cPanel dedicated servers.

How to Remove AutoSSL Excluded Domains from Command Line

AutoSSL excluded domains are domains which are explicitly excluded from AutoSSL SSL management and renewal processes.

To remove AutoSSL excluded domains from command line, follow the steps below:

  1. SSH the server as root or utilize the WHM 'Terminal' interface.
  2. Run the corresponding command (based on intended result):
    • List all users having domains excluded from AutoSSL:
      whmapi1 listaccts --output=json | jq -r '.data.acct[].user' | while read user ; do echo $user ; whmapi1 --output=json get_autossl_user_excluded_domains username="$user" | jq -r '.data.payload[]' ; done
    • Remove all AutoSSL excluded domains for a specified user:
      user="SPECIFIED_USER" ; domains=$(whmapi1 --output=json get_autossl_user_excluded_domains username="$user" | jq -r '[.data.payload[].excluded_domain] | join(",")'); [[ -n "$domains" ]] && echo "Removing domains for $user: $domains" && uapi --user="$user" SSL remove_autossl_excluded_domains domains="$domains"e

      Replace 'SPECIFIED_USER' with the actual username of the specified account.

    • Remove AutoSSL excluded domains from all accounts (server-wide)::
      whmapi1 listaccts --output=json | jq -r '.data.acct[].user' | while read user; do domains=$(whmapi1 --output=json get_autossl_user_excluded_domains username="$user" | jq -r '[.data.payload[].excluded_domain] | join(",")'); [[ -n "$domains" ]] && echo "Removing domains for $user: $domains" && uapi --user="$user" SSL remove_autossl_excluded_domains domains="$domains"; done
  3. That's it!

Conclusion

You now know how to remove AutoSSL excluded domains from command line.

  • autossl, ssh, root
  • 0 Kunder som kunne bruge dette svar
Hjalp dette svar dig?

Relaterede artikler

Disable Network Manager on CentOS 7

This article will provide the steps to disable Network Manager in CentOS 7. Network Manager is...

Disable Network Manager on CentOS 6

This article will provide the steps to disable Network Manager in CentOS 6. Network Manager is...

How to Find the IP of cPanel/WHM Server

This tutorial is designed to troubleshoot and diagnose issues with cPanel license errors. Find...

Uninstall WHMXtra on cPanel Server

This article provides a quick and direct guide for uninstalling the WHMXtra plugin from a...

How to Customize cPanel Installation

This article provides a guide for customizing a cPanel server installation, using the...