nginx-proxy-manager: 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

Error: Command failed: certbot certonly --config “/etc/letsencrypt.ini” --cert-name “npm-13” --agree-tos --email “AAAA@AAAA.com” --domains “*.AAA.com” --authenticator dns-aliyun --dns-aliyun-credentials “/etc/letsencrypt/credentials/credentials-13” An unexpected error occurred: AttributeError: module ‘certbot.interfaces’ has no attribute ‘IAuthenticator’ Ask for help or search for solutions at https://community.letsencrypt.org. See the logfile /tmp/certbot-log-i3b4nos8/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)

Nginx Proxy Manager Version

v2.9.19

To Reproduce Steps to reproduce the behavior:

  1. Go to 'SSL Certificates. Add Let’s Encrypt Certificate.Domain Names : *.AAA.COM.
  2. ADD Email Address for Let’s Encrypt .
  3. OPEN USER A DNS CHALLENGE。
  4. change DNS Provider is Aliyun,

dns_aliyun_access_key = KKKKEEEYYY dns_aliyun_access_key_secret = secretsecretsecretsecret

  1. Click on save
  2. Scroll down to ‘…’
  3. See error

Expected behavior

Screenshots

Operating System

Additional context

About this issue

Most upvoted comments

This Works as Temporary Workaround for me.

Open the Container Shell docker exec -it nginxproxymanager_app_1 /bin/bash

apt update apt dist-upgrade apt install python3 python3-venv libaugeas0 python3 -m venv /opt/certbot/ /opt/certbot/bin/pip install --upgrade pip /opt/certbot/bin/pip install certbot==1.32.0 certbot-apache==1.32.0 acme==1.32.0

This problem is caused by the wrong version of certbot, please go inside the docker container and execute the following command 👇

apt update
apt dist-upgrade
apt install python3 python3-venv libaugeas0
python3 -m venv /opt/certbot/
pip3 install --upgrade pip
pip3 install certbot==1.32.0 certbot-apache==1.32.0 acme==1.32.0

Please take care to backup your data

I can confirm that https://github.com/NginxProxyManager/nginx-proxy-manager/issues/2430#issuecomment-1329981484 fixed it. But certain lines are not needed and can be confusing for others, so the updated one:

apt update; apt upgrade -y
apt install -y libaugeas0
pip3 install --upgrade pip
pip3 install certbot==1.32.0 certbot-apache==1.32.0 acme==1.32.0

# Clean up cache [optional]
apt clean
pip3 cache purge

Note: I had to request the certifate twice from LetsEncrypt. My first trial gave an error (a different one), so you might need to try a few times until you get it.

Thanks @Rynal @skay-zhang

This is it. It’s what finally worked for me. DNS provider for GoDaddy was leading to the failure, but only because it bumped the version of certbot above 2.

I mixed a few approaches from above, but the key for me was pinning all the important certbot packages down to 1.32 while installing the DNS provider package with the following:

apt update && apt upgrade -y && apt install -y libaugeas0
pip3 install --upgrade pip
pip3 install certbot==1.32.0 certbot-nginx==1.32.0 acme==1.32.0 certbot-dns-godaddy

Same issue, with PowerDNS

This Works as Temporary Workaround for me.

Open the Container Shell docker exec -it nginxproxymanager_app_1 /bin/bash

apt update apt dist-upgrade apt install python3 python3-venv libaugeas0 python3 -m venv /opt/certbot/ /opt/certbot/bin/pip install --upgrade pip /opt/certbot/bin/pip install certbot==1.32.0 certbot-apache==1.32.0 acme==1.32.0

This worked for me, but had to use command “pip3” instead of “/opt/certbot/bin/pip”