nginx-proxy-manager: New DuckDNS certificate yields: AttributeError: module 'certbot.interfaces' has no attribute 'IAuthenticator'

Checklist

  • Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?
    • Yes
  • Are you sure you’re not using someone else’s docker image?
    • Yes
  • Have you searched for similar issues (both open and closed)?
    • Yes

Describe the bug

When I try to get a new certificate I get an Internal Error I thought there was something wrong with my settings so I tried with a lot of different variations, restarting docker, restarting the system, etc, but got the error every time. I went into the logs & saw this error An unexpected error occurred: AttributeError: module 'certbot.interfaces' has no attribute 'IAuthenticator'

I tried altering a bunch of different things but always had the same error. I edited an existing Host that was working fine & requested a new certificate & got the same error. I created a new Docker that was essentially the same as the old one in the docker compose but went to a different directory for the mounts. When trying to run it I ran into an error because I have mapped - /g/docker/nginx/nginx.conf:/etc/nginx/nginx.conf because there’s no other way to have the nginx.config persist without having the whole /etc/nginx directory which causes problems. I copied over the nginx.conf from the previous installation & started the app anew, creating the user account & then attempting to create a host. When I did I got the same Internal Error again. I removed the mapping for the nginx.conf, started the container copied it’s nginx.conf from the CLI to a directory that was mapped, & replaced the old one with the new one, then deleted everything except for that & started fresh again. I got to the Adding a Host point & again ran into an Internal Error which was again in the logs with a An unexpected error occurred: AttributeError: module 'certbot.interfaces' has no attribute 'IAuthenticator' A clean install has the same problem, so I’m now certain the error in not mine but with the app itself. Also in the logs, at least the last few rounds I tried, is this error [11/25/2022] [4:28:32 AM] [Express ] › ⚠ warning Command failed: certbot certonly --config "/etc/letsencrypt.ini" --cert-name "npm-1" --agree-tos --email "##REDACTED##" --domains "##REDACTED##" --authenticator dns-duckdns --dns-duckdns-credentials "/etc/letsencrypt/credentials/credentials-1" I also have confirmed the domains are correct & have tried different domains that are currently active in my old-version so long as I do not attempt to get an updated certificate for them.

Nginx Proxy Manager Version

v2.9.19 © 2022 jc21.com. Theme by Tabler

To Reproduce Steps to reproduce the behavior:

  1. Go to Proxy Hosts
  2. Click on Add Proxy Host or edit a current Proxy Host
  3. Go to SSL
  4. Request a new SSL certificate with Let's Encrypt
  5. Enable Force SSL
  6. Use a DNS Challenge
  7. DNS Provider: DuckDNS
  8. Copy-Paste Duck DNS Token from duckdns.org: dns_duckdns_token=STRING-OF-NUMBERS-&-DASHES-FROM-DUCKDNS
  9. I Agree to the Let's Encrypt Terms of Service
  10. See Internal Error
  11. Goto Logs
  12. See error

Expected behavior

It to work properly & add a Host & get a new SSL certificate

Screenshots

Operating System

  • Windows 10 Pro 21H2 - 19044.2130
  • Docker Desktop 4.14.1 (91661)
  • Portainer Business Edition 2.16.2 (Not in Swarm mode)
  • Portainer Stack
version: "3"
services:
  nginx_proxy:
    image: 'jc21/nginx-proxy-manager:latest'
    container_name: nginx_proxy
    restart: unless-stopped
    ports:
      - 80:80
      - 443:443
      - 81:81
    environment:
      DISABLE_IPV6: 'true'
    volumes:
      - /g/docker/nginx/nginx.conf:/etc/nginx/nginx.conf
      - /g/docker/nginx/log:/var/log
      - /g/docker/nginx/data:/data
      - /g/docker/nginx/letsencrypt:/etc/letsencrypt
      - /g/docker/nginx/www:/var/www
      - /g/docker/nginx/images:/var/images

Additional context

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 5
  • Comments: 16

Most upvoted comments

There’s an updated Docker image with a possible fix ( see PR #2411 ):

jc21/nginx-proxy-manager:github-pr-2411

Please test this and report your findings in the PR comments. Also note that renewals are also failing, so make sure to check the expiry of your certificates to prevent unexpected downtime.

Tried the new one… with success

the first ~10 minutes i get following error of multiple instances
Error: Command failed: certbot certonly --config "/etc/letsencrypt.ini" --cert-name "npm-80" --agree-tos --email "EMAIL_REMOVED" --domains "*.EXAMPLE.dev,EXAMPLE.dev" --authenticator dns-hetzner --dns-hetzner-credentials "/etc/letsencrypt/credentials/credentials-80"
Another instance of Certbot is already running.
Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /tmp/certbot-log-0d844pcc/log or re-run Certbot with -v for more details.

    at ChildProcess.exithandler (node:child_process:402:12)
    at ChildProcess.emit (node:events:513:28)
    at maybeClose (node:internal/child_process:1100:16)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)

After ~10 minutes its working again! - thx @rmoesbergen

image

Well, that last post was made & I realized I was looking at it wrong, since that tags are listed alphabetically 2.9.19 comes before 2.9.9. So far I have tried 2.9.19, 2.9.18, 2.9.17, 2.9.16 with the same result. So I now believe that the issue is that something with letsencrypt has changed & NGINX just hasn’t changed to meet whatever it now need to to work

Looking into it a bit I found a few things, but they all point to the same event from last year or older.

September 29, 2021 there was a change to their certificates system that seemed to cause a similar type of problem, but that was over a year ago & I don’t see anything newer than that. https://twitter.com/letsencrypt/status/1443248706166398984