Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. https://crt.sh/?q=example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.
I ran this command: sudo certbot --server https://acme-v02.api.letsencrypt.org/directory -d goingplaces.me -d *.goingplaces.me --manual --preferred-challenges dns-01 certonly
It produced this output:
Press Enter to Continue
Waiting for verification...
Cleaning up challenges
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at:
/etc/letsencrypt/live/goingplaces.me-0001/fullchain.pem
Your key file has been saved at:
/etc/letsencrypt/live/goingplaces.me-0001/privkey.pem
Your cert will expire on 2018-12-22. To obtain a new or tweaked
version of this certificate in the future, simply run certbot
again. To non-interactively renew *all* of your certificates, run
"certbot renew"
- If you like Certbot, please consider supporting our work by:
Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate
Donating to EFF: https://eff.org/donate-le
My web server is (include version):
nginx version: nginx/1.10.3 (Ubuntu)
The operating system my web server runs on is (include version):
Ubuntu 16.04.4 LTS
My hosting provider, if applicable, is: Digital Ocean
I can login to a root shell on my machine (yes or no, or I don’t know): Yes
I’m using a control panel to manage my site (no, or provide the name and version of the control panel):no
Problem:
I got confirmation that certificate was issued. Its working fine on main domain https://goingplaces.me/ however whenever I am trying to access subdomain, e.g. https://conquistadorjd.goingplaces.me/, I am getting privacy error i.e. ssl is not working fine on the subdomain.
here is the screenshot
Do you have a ssl/tls/ port 443 virtual host that listens on that subdomain? You’ll need to install the certificate on all virtual hosts that need to use this certificate.
Also, the certificate on goingplaces.me does not look like the certificate you requested recently…
So I would conclude that you obtained a certificate, but never attempted to install it… (Since you used certonly and did not ask certbot to install the certificate for you)
Can you find a virtual host (that listens on port 443) that contains your subdomain as a server_name? (There’s no mention of the subdomain in the currently using virtual host)
Also, you’ll need to install the certificate by yourself in order to use the certificate… It’s definitely not installed.
When you say, I need to install certificate, are you referring to base domain goingplaces.me or the wildcard for goingplaces.me (like *.goingplaces.me ) ?
SSL is working fine for goingplaces.me
1.- certbot said that the wildcard certificate has been saved here /etc/letsencrypt/live/goingplaces.me-0001/fullchain.pem (pay attention to suffix -0001).
2.-certbot certificates only shows a certificate located in /etc/letsencrypt/live/goingplaces.me/fullchain.pem, did you paste the entire output?.
3.- In your nginx conf the certificate used for your domain is located at /etc/letsencrypt/live/techtrekking.com/fullchain.pem which seems wrong if you want to use the wildcard cert.
Did you manually modify, delete something in /etc/letsencrypt/ ?.
Could you please show the output of these commands?
ls -lR /etc/letsencrypt/live/
ls -lR /etc/letsencrypt/archive/
ls -l /etc/letsencrypt/renewal/
After reading these three points, I just realised my mistake. I have updated my NGIX file to correct the live location as below
# managed by Certbot
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/goingplaces.me/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/goingplaces.me/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
This is now working as expected. I tested this with completely new subdomain and this is working smoothly.
here is the screenshot
I did not rename the dir. I created and deleted certificate multiple times today. Could this be due to requesting new certificate without deleting earlier one ?
Here is the output that you requested
# renew_before_expiry = 30 days
version = 0.27.1
archive_dir = /etc/letsencrypt/archive/goingplaces.me
cert = /etc/letsencrypt/live/goingplaces.me/cert.pem
privkey = /etc/letsencrypt/live/goingplaces.me/privkey.pem
chain = /etc/letsencrypt/live/goingplaces.me/chain.pem
fullchain = /etc/letsencrypt/live/goingplaces.me/fullchain.pem
# Options used in the renewal process
[renewalparams]
account = be9d4a4f2ee0eac4d875003c3ee73575
pref_challs = dns-01,
server = https://acme-v02.api.letsencrypt.org/directory
authenticator = manual
manual_public_ip_logging_ok = True
Yes, that explains the weird issue, you created a new cert without removing the old one or without specifying parameter --cert-name so certbot created a new dir with -0001.
Just in case, keep in mind that as you are using a manual method to create the needed TXT records for your wildcard cert, it won't be renewed automatically and you should execute the same manual process the day you want to renew the certificate.
just a follow up question:
Current setup is not redirecting http to https. I remember while doing non wildcard setup, there was a question if I would like to redirect http to https, I did not see this while setting up wildcard ssl.
is it not available with wildcard SSL ?
Thank you. This resolved http issue. Note to anyone else running into same issue:
I added above code in my existing server block but this did not work. infact site went into redirect loop. I added above mentioned code above my first server block and its working fine now.