nginx-certbot icon indicating copy to clipboard operation
nginx-certbot copied to clipboard

Fails with no such file error

Open rlaferla opened this issue 6 years ago • 8 comments

nginx_1 | 2019/10/13 01:17:59 [emerg] 1#1: open() "/etc/letsencrypt/options-ssl-nginx.conf" failed (2: No such file or directory) in /etc/nginx/conf.d/app.conf:22 nginx_1 | nginx: [emerg] open() "/etc/letsencrypt/options-ssl-nginx.conf" failed (2: No such file or directory) in /etc/nginx/conf.d/app.conf:22 certbot_1 | Saving debug log to /var/log/letsencrypt/letsencrypt.log certbot_1 | certbot_1 | - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - certbot_1 | certbot_1 | No renewals were attempted. certbot_1 | - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

rlaferla avatar Oct 13 '19 01:10 rlaferla

The init-letsencrypt.sh requires that you create a "conf" subdirectory under "data" before you run it.

rlaferla avatar Oct 13 '19 02:10 rlaferla

This is actually an issue that can be resolved by adding the directory and file to this repository.

rlaferla avatar Oct 29 '19 15:10 rlaferla

Thanks for pointing this out! Would you create a pull request for the 2.x branch to add folder creation?

wmnnd avatar Oct 29 '19 16:10 wmnnd

I keep getting this problem. The script init-letsencrypt.sh is not working.

sharpist avatar Nov 20 '19 22:11 sharpist

ng01 | 2019/11/30 16:49:08 [emerg] 1#1: unexpected end of file, expecting ";" or "}" in /etc/letsencrypt/options-ssl-nginx.conf:2 ng01 | nginx: [emerg] unexpected end of file, expecting ";" or "}" in /etc/letsencrypt/options-ssl-nginx.conf:2 @wmnnd Tried to use v.2.x, but got this error Used this configuration - https://github.com/wmnnd/nginx-certbot/issues/52#issuecomment-553811146

tavor118 avatar Nov 30 '19 17:11 tavor118

There is the case that you have to make a few small changes to the init-letsencrypt.sh file in case that you are not using a single docker-compose.yml file. If you are using multiple docker-compose files you have to pass the file names to any docker-compose command. for example instead of: docker-compose run ... to replace it with the: docker-compose -f docker-compose.yml -f docker-compose.production.yml run ... There have to be done 5 replacements.

chrstsrs avatar Dec 31 '19 10:12 chrstsrs

Same problem. Have any solution?

nikolas-dev avatar Apr 26 '20 06:04 nikolas-dev

I think you may have to make changes to the init-letsencrypt.sh. Just adapt it to your needs (you can see a change in docker-compose commands in my previous post)

chrstsrs avatar Apr 27 '20 09:04 chrstsrs