404 with webroot

Hello, I have a problem, I tried installing the SSL certificate because I need the HTTPS for my api's. I developed the APIs in python with uvicorn. Thanks in advance.

My domain is: apipfg.servehttp.com

I ran this command: certbot certonly --webroot -w C:/inetpub/wwwroot -d apipfg.servehttp.com

It produced this output:
Domain: apipfg.servehttp.com
Type: unauthorized
Detail: XXX.XXX.XXX.XXX: Invalid response from http://apipfg.servehttp.com/.well-known/acme-challenge/fDAo47m4P-PoZknw2MWyA-09m4gPM_WRdpMM9l6267U: 404

My web server is (include version): uvicorn 0.24.0.post1

The operating system my web server runs on is (include version): Windows Server 2012R2

I can login to a root shell on my machine (yes or no, or I don't know): yes

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you're using Certbot): 2.9.0

1 Like

Please note that the Certbot team is discontinuing Windows support. See Certbot Discontinuing Windows Beta Support in 2024 for more information.

This looks like an IIS webroot? But you're not running IIS, right? Or does Uvicorn also serve files from C:/inetpub/wwwroot?


No, I’m not using IIS. And in python, the documentation tells me to make this code: app.mount("/.well-known", StaticFiles(directory="C:/inetpub/wwwroot/.well-known"), name="static")

Sorry, which documentation is that? Not the Certbot documentation, as far as I know.

The official documentation about Certbot's --webroot just says to specify

although it might be too terse there.