Question

How do I add a domain to an existing SSL certificate?

Posted August 30, 2021 104 views
Let's Encrypt

I created a one click install droplet and I believe SSL was automatically setup for a single domain.

However, I think I only added:
www.domain.com

and not

domain.com

to the SSL certificate and I want to make sure I have both.

Thanks

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
1 answer

Hi @madavormediallc,

You can always use certbot to renew your domain’s SSL and have it for both your domain.com and your www.domain.com.

If you let me know what One Click droplet you installed I’ll be able to give you more detailed instructions on how to proceed.

  • Hi,

    Thanks for the response! It was WordPress one click install.

    • Hi @madavormediallc,

      Thank you for the confirmation. The WordPress droplet comes with Apache so you can install certbot for Apache and install it.

      First, add the repository:

      sudo add-apt-repository ppa:certbot/certbot
      

      You’ll need to press ENTER to accept.

      Install Certbot’s Apache package with apt:

      sudo apt install python-certbot-apache
      

      Certbot is now ready to use, but in order for it to configure SSL for Apache, we need to verify some of Apache’s configuration.

      Certbot provides a variety of ways to obtain SSL certificates through plugins. The Apache plugin will take care of reconfiguring Apache and reloading the config whenever necessary. To use this plugin, type the following:

      sudo certbot --apache -d your_domain -d www.your_domain
      

      This runs certbot with the –apache plugin, using -d to specify the names you’d like the certificate to be valid for.