Report this

What is the reason for this report?

letsencrypt invalid SSL Cert

Posted on January 8, 2017
Phil

By Phil

I have just setup my website(nodejs) with nginx and using lets encrypt for the cert but having problems with “Invalid SSL Cerificate”

if I do a search examplesite.com it redirects to https://examplesite.com everything is fine but when If I search for www.examplesite.com it redirects to https://www.examplesite.com but gives me invalid ssl cerificate.

Anyone know whats going on?

Many thanks Phil



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

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.

@Phils

When you setup the certificate, did you specify both? If you do not pass both as options when creating the certificate, one will be valid and the other won’t.

When creating the certificate, you need to pass:

-d www.domain.com -d domain.com

as arguments.

You can delete the existing and simply recreate a new certificate by passing both instances of your domain and then restarting Apache/NGINX.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.