Letsencrypt in docker

Ubuntu server 18.04. I am administrator of this server.
I am owner of domain:
zurawscy.bialystok.pl

I am using this repository: GitHub - wmnnd/nginx-certbot: Boilerplate configuration for nginx and certbot with docker-compose
Article about this repository: Nginx and Let’s Encrypt with Docker in Less Than 5 Minutes | by Philipp | Medium
I created my own repository to show main files:
-docker-compose configuration
-nginx configuration
-script setup

The problem is that when I am running script then I get logs below:

Downloading recommended TLS parameters ...

Creating dummy certificate for zurawscy.bialystok.pl ...

Creating nginx-certbot_certbot_run ... done
Generating a RSA private key
..................................................................................................................++++
......................++++
writing new private key to '/etc/letsencrypt/live/zurawscy.bialystok.pl/privkey.pem'

Starting nginx ...

Creating nginx-certbot_nginx_1 ... done

Deleting dummy certificate for zurawscy.bialystok.pl ...

Creating nginx-certbot_certbot_run ... done

Requesting Let's Encrypt certificate for zurawscy.bialystok.pl ...

Creating nginx-certbot_certbot_run ... done
Saving debug log to /var/log/letsencrypt/letsencrypt.log


Would you be willing, once your first certificate is successfully issued, to
share your email address with the Electronic Frontier Foundation, a founding
partner of the Let's Encrypt project and the non-profit organization that
develops Certbot? We'd like to send you email about our work encrypting the web,
EFF news, campaigns, and ways to support digital freedom.


(Y)es/(N)o: N
Account registered.
Requesting a certificate for zurawscy.bialystok.pl and www.zurawscy.bialystok.pl

Certbot failed to authenticate some domains (authenticator: webroot). The Certificate Authority reported these problems:
Domain: zurawscy.bialystok.pl
Type: connection
Detail: Fetching http://zurawscy.bialystok.pl/.well-known/acme-challenge/AMUPnrdYmxhK_iV_h7iLlkgY7ODV2D6Ig0A2yZXP9zE: Connection refused

Domain: www.zurawscy.bialystok.pl
Type: connection
Detail: Fetching http://www.zurawscy.bialystok.pl/.well-known/acme-challenge/BPtzymsbnCOeh0p13IMb0l5TMxJz-7G7eUYuEtSwKDo: Connection refused

Hint: The Certificate Authority failed to download the temporary challenge files created by Certbot. Ensure that the listed domains serve their content from the provided --webroot-path/-w and that files created there can be downloaded from the internet.

Some challenges have failed.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /var/log/letsencrypt/letsencrypt.log or re-run Certbot with -v for more details.
ERROR: 1

Reloading nginx ...

Error response from daemon: Container 6c8ae622bb50b649bb78553dc70831da964299dcf2a40e859995f69f4bca2247 is restarting, wait until the container is running

When I was doing the same a few days ago, everything worked properly. I think it's case of some cache, but I am not sure how to disable it. What do You think about it?

That seems like a firewall problem.
OR
A misconfiguration.
You must have a working HTTP site before it can be secured (via HTTP authentication).
Is the HTTP site still working?

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.