addon-nginx-proxy-manager icon indicating copy to clipboard operation
addon-nginx-proxy-manager copied to clipboard

certbot / godaddy auth issue after update - cannot import name 'ClientBase' from 'acme.client'

Open seancmalloy opened this issue 1 year ago • 14 comments

Problem/Motivation

NGINX proxy manager fails to import name 'ClientBase' from 'acme.client'

(Why the issue was filed)

Expected behavior

renew certificate with godaddy credentials

(What you expected to happen)

Actual behavior

fails at cannot import name 'ClientBase' from 'acme.client'

(What actually happened)

Steps to reproduce

verified dns records, verified port open, recreated godaddy api key - uninstalled addon and deleted data, reinstalled addon

(How can someone else make/see it happen)

Logs

[1/13/2024] [3:19:16 PM] [Nginx ] › ℹ info Reloading Nginx [1/13/2024] [3:19:16 PM] [SSL ] › ℹ info Requesting Let'sEncrypt certificates via GoDaddy for Cert #1: my.domain.com [1/13/2024] [3:19:16 PM] [SSL ] › ℹ info Command: mkdir -p /etc/letsencrypt/credentials 2> /dev/null; echo 'dns_godaddy_secret = mysecret dns_godaddy_key = mykey' > '/etc/letsencrypt/credentials/credentials-1' && chmod 600 '/etc/letsencrypt/credentials/credentials-1' && pip install certbot-dns-godaddy~=0.2.0 && certbot certonly --config "/etc/letsencrypt.ini" --work-dir "/tmp/letsencrypt-lib" --logs-dir "/tmp/letsencrypt-log" --cert-name "npm-1" --agree-tos --email "[email protected]" --domains "my.domain.com" --authenticator dns-godaddy --dns-godaddy-credentials "/etc/letsencrypt/credentials/credentials-1" [1/13/2024] [3:20:00 PM] [Nginx ] › ℹ info Reloading Nginx [1/13/2024] [3:20:00 PM] [Express ] › ⚠ warning Command failed: certbot certonly --config "/etc/letsencrypt.ini" --work-dir "/tmp/letsencrypt-lib" --logs-dir "/tmp/letsencrypt-log" --cert-name "npm-1" --agree-tos --email "[email protected]" --domains "my.domain.com" --authenticator dns-godaddy --dns-godaddy-credentials "/etc/letsencrypt/credentials/credentials-1" Traceback (most recent call last): File "/usr/bin/certbot", line 5, in from certbot.main import main File "/usr/lib/python3.11/site-packages/certbot/main.py", line 6, in from certbot._internal import main as internal_main File "/usr/lib/python3.11/site-packages/certbot/_internal/main.py", line 28, in from certbot import crypto_util File "/usr/lib/python3.11/site-packages/certbot/crypto_util.py", line 42, in from certbot import interfaces File "/usr/lib/python3.11/site-packages/certbot/interfaces.py", line 21, in from acme.client import ClientBase ImportError: cannot import name 'ClientBase' from 'acme.client' (/usr/lib/python3.11/site-packages/acme/client.py)

seancmalloy avatar Jan 13 '24 20:01 seancmalloy

+1

PodgyMonkey avatar Jan 14 '24 07:01 PodgyMonkey

Getting the same issue. In addition, when trying to test the connection to check if the addon has network connectivity, this error occurs. Not sure if related. I can create another issue if it is not. Error:

-----------------------------------------------------------
 Add-on: Nginx Proxy Manager
 Manage Nginx proxy hosts with a simple, powerful interface
-----------------------------------------------------------
 Add-on version: 1.0.1
 You are running the latest version of this add-on.
 System: Home Assistant OS 11.4  (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2024.1.3
 Home Assistant Supervisor: 2023.12.0
-----------------------------------------------------------

... SNIPPING OUT NORMAL STARTUP ...

[1/14/2024] [10:33:28 AM] [SSL      ] › ℹ  info      Testing http challenge for <DOMAIN>
Uncaught SyntaxError: Unexpected end of JSON input

FROM
2024/01/14 10:33:29 [error] 227#227: *14 upstream prematurely closed connection while reading response header from upstream, client: <MyClientIP>, server: nginxproxymanager, request: "GET /api/nginx/certificates/test-http?domains=%5B%22<DOMAIN>%22%5D HTTP/1.1", upstream: "http://127.0.0.1:3000/nginx/certificates/test-http?domains=%5B%22<DOMAIN>%22%5D", host: "<HomeAssistantIP>:81", referrer: "http://<HomeAssistantIP>:81/nginx/certificates"
JSON.parse (<anonymous>)IncomingMessage.<anonymous> (/opt/nginx-proxy-manager/internal/certificate.js:1178:31)IncomingMessage.emit (node:events:529:35)endReadableNT (node:internal/streams/readable:1400:12)process.processTicksAndRejections (node:internal/process/task_queues:82:21)[10:33:29] INFO: Service Nginx Proxy Manager exited with code 256 (by signal 5)

pwnpanda avatar Jan 14 '24 09:01 pwnpanda

@pwnpanda About the network connectivity issue: Let's not mix up multiple issues in a single report.

Getting the same issue.

Also using godaddy? Or are you using a different provider?

frenck avatar Jan 14 '24 09:01 frenck

@pwnpanda About the network connectivity issue: Let's not mix up multiple issues in a single report.

Getting the same issue.

Also using godaddy? Or are you using a different provider?

Yes, also using godaddy!

I completely understand, will make a new issue so it can be tracked :)

pwnpanda avatar Jan 14 '24 11:01 pwnpanda

Same issue for me, seems like it relates to the discussion in https://github.com/NginxProxyManager/nginx-proxy-manager/pull/3165

DanielTheCoder avatar Jan 21 '24 15:01 DanielTheCoder

I have updated from 0.12.3 to 1.0.1 and my domain is hosted by GoDaddy. I am getting an "Internal error" message when adding the domain to the configuration and forcing a certificate renewal.

Downgrading to 0.12.3 makes everything work again.

PAHVelthuis avatar Jan 22 '24 21:01 PAHVelthuis

I updated yeterday from 0.12.3 to 1.0.1 and in the initial setup process I saw the problem descirbed here with godaddy DNS challenge.

NatroNx avatar Feb 02 '24 07:02 NatroNx

Following this from #507 - my post

RASBR avatar Feb 23 '24 07:02 RASBR

I am also experiencing this issue

gricey avatar Feb 27 '24 20:02 gricey

yeah the linked issue seems related. Hopefully they gonna fix it

NatroNx avatar Mar 18 '24 20:03 NatroNx

I have this issue on v2.10.4 for GoDaddy. Upgraded to v2.11.1 and had different error message, sadly I didn't note it down since I was in a hurry. Reverted to v2.10.4 and ran these into the container:

cd /opt/certbot
/opt/certbot/bin/pip install acme==1.32.0

Renewal worked afterwards. I'll se you guys again in 3 months with errors from the latest version, if the issue is not resolved :)

Kegelcizer avatar Mar 19 '24 10:03 Kegelcizer

Using 2.11.1 on my Docker host all my certificates from GoDaddy generated successfully, I tried renewing one of them and it did as well. Will wait and see in 3 months time if all will renew automatically.

RASBR avatar Mar 19 '24 15:03 RASBR

Hello, same error for me with npm rev 1.0.1 and GoDaddy

aymenSo avatar Mar 26 '24 08:03 aymenSo

I just transferred my domains to domain.com and nginx proxy manager ha addon was able request new certs (no dns challenge like godaddy) no problem. easy-peasy

seancmalloy avatar Apr 02 '24 19:04 seancmalloy

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!

github-actions[bot] avatar May 03 '24 08:05 github-actions[bot]