I try to delete the two certificates but I have the same problem.
For apache configuration, i do not know where i could do that.
In /etc/apache2/sites-available/asuto-le-ssl.conf the ssl certificates are quoted, but it is the only file and I do not see what modification to make therefore.
ServerName astuto.fr
ServerAlias www.astuto.fr
Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /etc/letsencrypt/live/astuto.fr/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/astuto.fr/privkey.pem
I understand that what you are advising me to do, is only to change the configuration of Apache, but if I do it it does not work.
The real question is why the same certificate can not work with and without the www?
I guess elsewhere it works but not to my configuration.
My priority is that astuto.fr works (without www) so I have one last time renewed the certificate. I saw that it changed the file /etc/apache2/sites-available/asuto-le-ssl.conf to remove the www in those two directives letsencrypt/
So simply putting the www is not the solution.
I will try another solution for today but all ideas will be welcome.
If you can get Apache to use the certificate that includes both names, it will work.
What command did you run? Please don't run it again, just say what it was.
If you run Certbot and tell it to reinstall one of the existing certificates without issuing a new one, it can try to configure Apache to use that certificate. (But depending on your Apache configuration, it might not update all the right virtual hosts.)
But you can also modify the Apache configuration by hand to make the same changes.
Can you post the output of “certbot-auto certificates” again?
Right now, https://astuto.fr/ is using a certificate for astuto.fr that was issued about half an hour ago.
https://www.astuto.fr/ now has a different IP address pointing to a different computer, using some certificate for cluster006.hosting.ovh.net.
astuto.fr. 1304 A 51.38.48.80
www.astuto.fr. 1307 A 213.186.33.17
As I can not generate the www certificate I use a backup solution through an all in one web hoster for the www.
All command run but it doesn't work.
I have 2 certificates again because with /etc/letsencrypt/live/www.astuto.fr/privkey.pem "astuto.fr" doesn't work.
/bin/certbot-auto has insecure permissions!
To learn how to fix them, visit Certbot-auto deployment best practices
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Thank you for your help, I will continue testing tomorrow.
Here is the result of the command sudo apachectl -t -D DUMP_VHOSTS
VirtualHost configuration:
*:443 astuto.fr (/etc/apache2/sites-enabled/astuto-le-ssl.conf:;0;2)
*:80 is a NameVirtualHost
default server v.ovh.net (/etc/apache2/sites-enabled/000-default.conf:1)
port 80 namevhost v.ovh.net (/etc/apache2/sites-enabled/000-default.conf:1)
port 80 namevhost astuto.fr (/etc/apache2/sites-enabled/astuto.conf:1)
alias www.astuto.fr