Unable to Generate SSL cert using docker-compose

The "404" is an HTTP Not Found error. It means you are using an HTTP Challenge (probably webroot since you don't show command I have to guess). For webroot acme.sh places a challenge token file in the webroot folder you specify. The Let's Encrypt server then makes an HTTP request to your domain requesting that challenge file. But, your nginx says it was not found.

With multiple docker containers, this usually means the webroot folder for acme.sh is not your nginx root folder for this domain. Check your volume statements to be sure these map to the same location.

2 Likes