I guess that example is what it is because Certbot is making the changes. Therfore that is what the nginx conf will look like after the automatet changes are made.
Anyway. I have a fully functional port 80 way into my server. I can reach it. But I get 404 error when trying to create the cert.
Maybe the Certbot is trying to create the file in wrong path?
We can also try using --webroot method:
Where you replace --nginx from the command with: --webroot -w /var/www/html
[NOTE: webroot MUST USE THE SAME root FOLDER AS IN YOUR CONFIG FILE]
[so change that path to match your actual path]
Does that path exist?
If so, then it can be used in the command: sudo certbot --nginx -d example.com -d www.example.com
as sudo certbot certonly --webroot -w /var/www/html -d example.com -d www.example.com
Yes I finally got Congratulations. Now I’m looking into why I still can’t connect to my webserver via https. But I want to struggle some before asking about this.
I cannot give better advice than to ask your hosting provider to supply a PLESK management console.
With that it is as simple as ABC. If your hosting provider cannot help you, change your hosting provider!