wmnnd / nginx-certbot

Boilerplate configuration for nginx and certbot with docker-compose
MIT License
3.16k stars 1.17k forks source link

Nginx container stuck in a restart loop #125

Closed Kyawn88 closed 2 years ago

Kyawn88 commented 2 years ago

I've copied the configuration to the letter and the setup doesn't seem to work (I get no SSL working).

I noticed that I had accidentally placed my app.conf file in my home directory rather than in the data/nginx/ directory, the problem is that after placing the app.conf file into the binded directory the nginx container just gets stuck in a perpetual state of restarting.

Am I missing something here?

Kyawn88 commented 2 years ago

This is a non issue, after interrogating the logs further I discovered that the certificates were not generated porperly first time round using the init-letsencrypt script, the failure to find the non-existent certificates threw nginx into a reboot loop.

After re-running the script it was able to successfully generate the certificates and now nginx comes up and stays up.