mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2026-04-26 01:45:54 +03:00
[GH-ISSUE #967] Unable to auto renew certificate using Cloudflare DNS validation #812
Labels
No labels
awaiting feedback
bug
cannot reproduce
dns provider request
duplicate
enhancement
enhancement
enhancement
good first issue
help wanted
invalid
need more info
no certbot plugin available
product-support
pull-request
question
stale
troll
upstream issue
v2
v2
v2
v3
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/nginx-proxy-manager-NginxProxyManager#812
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @evolsano on GitHub (Mar 22, 2021).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/967
Are you in the right place?
Checklist
jc21/nginx-proxy-manager:latestdocker image? yes.Describe the bug
I am running NPM in 2 different Ubuntu 18.04 LTS server. I am using Cloudflare DNS validation.
Both NPM docker failed to renew Let's Encrypt wildcard certificate with auto renewal. But able to renew it when run it manually in SSL Certificate tab.
What version of Nginx Proxy Manager is reported on the login page? 2.8.1
Expected behavior
Expect auto certificate renewal when close to expiry.
Screenshots
If applicable, add screenshots to help explain your problem.
Operating System
Additional context
Auto renewal
Renew manually
@fanvyr commented on GitHub (Mar 30, 2021):
Do you use Cloudflare in proxy mode? You can't use wildcard SSL Certs with that.
To obtain a certificate i would recommend turning the proxy mode off, issue the cert, and turn it back on.
Had issues with that too.
@evolsano commented on GitHub (Apr 4, 2021):
What is proxy mode? I can renew the certificate manually, but not automatically.
@fanvyr commented on GitHub (Apr 4, 2021):
When viewing the matching DNS record, is the Cloud Symbol Orange or Grey?
Orange = Proxy mode
Grey = direct exposing
@ikomhoog commented on GitHub (Apr 4, 2021):
I have the same issue, I have all my records without Cloudflare proxy, just the grey cloud symbol.
But when I try it manually I get a timeout error.
I got this log 2x repeated:
While writing this I saw this log popup, I don't know if this is automatic or induced by me trying to manually renew it after boot:
After another Manual try with timeout error it did actually work:
So my certs have now renewed but I would like it to also work automatically/more reliably.
Is there anything I can do to try and help find a solution to this?
@ArtisanByteCrafter commented on GitHub (Apr 6, 2021):
Exact same issue here, fails auto-renew, but manual works, even though GUI returns blank error screen. happy to help if I can provide any additional info.
@WalterPinkman commented on GitHub (Apr 8, 2021):
I'm experiencing the same issue. I use Cloudflare DNS challenge for several LE certificates. Auto renewing fails. Manual renewing via the web GUI is very slow, but works.
Auto Renewing
Manual Renewing via web GUI
@ikomhoog commented on GitHub (Apr 12, 2021):
I have just discovered that i have 733 "csr-certbot.pem" and "key-certbot.pem" files.

These we all from the 30 days up to my cert expiry date, which is when NPM starts trying to renew them if I'm not mistaken.
Maybe the others that have the same issue also have these files?
It could be something to finding out what is going wrong.
@ArtisanByteCrafter commented on GitHub (Apr 12, 2021):
I appear to have the same.

I only had 146 files, but I believe I manually renewed within a few days of discovering it wasn't auto-renewing, so I may have less due to this.
@trenetics commented on GitHub (Apr 14, 2021):
Experiencing same problems here as well, auto renewal fails, manual works but takes like 5 minutes pr renawal.
@caphm commented on GitHub (Apr 14, 2021):
Having exactly the same issues. Same log output. Same result when trying to manually renew (GUI shows an error, but renewal works). I've had over 2100 *.pem files in my "keys" directory...
@trenetics commented on GitHub (Apr 15, 2021):
I have like 4000... Can i delete them without breaking anything?
@caphm commented on GitHub (Apr 16, 2021):
All except the newest one, I guess. I did so an it didn't break anything.
@fabiandev commented on GitHub (Jun 7, 2021):
I had the exact same issue, and this is what seems to solve the problem for me, as the default
letsencrypt.iniexplicitly defineswebrootasauthenticator:letsencrypt.iniandcloudflare.inifilesletsencrypt.iniand mountcloudflare.iniDNS_CLOUDFLARE_CREDENTIALSto environmentletsencrypt.inicloudflare.inidocker-compose.ymlAfter recreating the container, the certificates renewed automatically and the expiry date is also correct in the UI.
Before:
After:
@WalterPinkman commented on GitHub (Jun 7, 2021):
Thank you very much for sharing your solution. I can happily share that it worked for me as well.
@ikomhoog commented on GitHub (Jun 12, 2021):
@fabiandev thanks for the fix.
I just used the letsencrypt.ini with
And that was enough for it to work.
@github-actions[bot] commented on GitHub (Mar 16, 2024):
Issue is now considered stale. If you want to keep it open, please comment 👍
@github-actions[bot] commented on GitHub (Apr 27, 2025):
Issue was closed due to inactivity.