[Bug]: oidc fails with callback - ENOTFOUND #3111

Open
opened 2026-02-20 11:00:32 -05:00 by deekerman · 4 comments
Owner

Originally created by @cwiggs on GitHub (Nov 23, 2025).

What happened?

Hello,

I am trying to get audiobookshelf setup to with with oidc. The oidc provider I'm using is Authelia and It is working fine with various other apps (ArgoCD, Proxmox, etc). However when I set it up with Audiobookshelf And I click the "Login with OpenId" button it takes me to Authelia to login and then I reports back "Error in callback" When I check the audiobookshelf container logs I see this:

ERROR: "[Auth] Error in openid callback - Error: getaddrinfo ENOTFOUND auth..com

I verified that coredns is setup properly and responds to the dns request properly. I also exec-ed into the audiobookshelf container and checked that the container resolves properly:

/app # nslookup -type=A auth.<redacted>.com
Server:         10.43.0.10
Address:        10.43.0.10:53

Non-authoritative answer:
auth.cwiggs.com canonical name = ingress-nginx.<redacted>.com
Name:   ingress-nginx.<redacted>.com
Address: 10.26.9.203

I also checked the authelia logs and I see the oidc was successful there.

From what I understand ENOTFOUND is a DNS resolution error, but I'm not sure why audiobookshelf cannot resolve the name when the container can.

Thanks

What did you expect to happen?

Be able to login with oidc

Steps to reproduce the issue

  1. Setup authelia with audiobookshelf config
  2. Update audiobookshelf config to use authelia for oidc auth.
  3. Try to login with oidc in audiobookshelf

Audiobookshelf version

2.30.0

How are you running audiobookshelf?

Other (list in "Additional Notes" box)

What OS is your Audiobookshelf server hosted from?

Linux

If the issue is being seen in the UI, what browsers are you seeing the problem on?

Firefox

Logs

[2025-11-23 13:50:54.728] DEBUG: [OidcAuth] OIDC redirect_uri=https://ebooks.home.cwiggs.com/auth/openid/callback                              
[2025-11-23 13:50:54.730] DEBUG: [Auth] paramsToCookies: setting auth_method cookie to openid                                                  
[2025-11-23 13:50:56.157] ERROR: "[Auth] Error in openid callback - Error: getaddrinfo ENOTFOUND auth.<redacted>.com"

Additional Notes

I am running audoibookshelf in Kubernetes (k3s)

Originally created by @cwiggs on GitHub (Nov 23, 2025). ### What happened? Hello, I am trying to get audiobookshelf setup to with with oidc. The oidc provider I'm using is Authelia and It is working fine with various other apps (ArgoCD, Proxmox, etc). However when I set it up with Audiobookshelf And I click the "Login with OpenId" button it takes me to Authelia to login and then I reports back "Error in callback" When I check the audiobookshelf container logs I see this: > ERROR: "[Auth] Error in openid callback - Error: getaddrinfo ENOTFOUND auth.<redacted>.com I verified that coredns is setup properly and responds to the dns request properly. I also exec-ed into the audiobookshelf container and checked that the container resolves properly: ``` /app # nslookup -type=A auth.<redacted>.com Server: 10.43.0.10 Address: 10.43.0.10:53 Non-authoritative answer: auth.cwiggs.com canonical name = ingress-nginx.<redacted>.com Name: ingress-nginx.<redacted>.com Address: 10.26.9.203 ``` I also checked the authelia logs and I see the oidc was successful there. From what I understand `ENOTFOUND` is a DNS resolution error, but I'm not sure why audiobookshelf cannot resolve the name when the container can. Thanks ### What did you expect to happen? Be able to login with oidc ### Steps to reproduce the issue 1. Setup authelia with audiobookshelf config 2. Update audiobookshelf config to use authelia for oidc auth. 3. Try to login with oidc in audiobookshelf ### Audiobookshelf version 2.30.0 ### How are you running audiobookshelf? Other (list in "Additional Notes" box) ### What OS is your Audiobookshelf server hosted from? Linux ### If the issue is being seen in the UI, what browsers are you seeing the problem on? Firefox ### Logs ```shell [2025-11-23 13:50:54.728] DEBUG: [OidcAuth] OIDC redirect_uri=https://ebooks.home.cwiggs.com/auth/openid/callback [2025-11-23 13:50:54.730] DEBUG: [Auth] paramsToCookies: setting auth_method cookie to openid [2025-11-23 13:50:56.157] ERROR: "[Auth] Error in openid callback - Error: getaddrinfo ENOTFOUND auth.<redacted>.com" ``` ### Additional Notes I am running audoibookshelf in Kubernetes (k3s)
Author
Owner

@cwiggs commented on GitHub (Nov 23, 2025):

Looks like I was able to get this working but updating the DNS record from a CNAME to an A record. Not sure why that was making it fail though.

@cwiggs commented on GitHub (Nov 23, 2025): Looks like I was able to get this working but updating the DNS record from a CNAME to an A record. Not sure why that was making it fail though.
Author
Owner

@davidedpg10 commented on GitHub (Nov 26, 2025):

I'm having this issue but with the Match functionality that retrieves data from providers such as Audible.com

[Audible] query search error getaddrinfo ENOTFOUND api.audible.com

But if I go into the container, I can reach the internet and even resolve the address.

Also running in Kubernetes (k3s)

@davidedpg10 commented on GitHub (Nov 26, 2025): I'm having this issue but with the `Match` functionality that retrieves data from providers such as Audible.com ``` [Audible] query search error getaddrinfo ENOTFOUND api.audible.com ``` But if I go into the container, I can reach the internet and even resolve the address. Also running in Kubernetes (k3s)
Author
Owner

@jhaydter commented on GitHub (Dec 9, 2025):

Encountered this as well on v2.31 in docker. I had to fix my DNS to resolve the oidc dns name the error references.

@jhaydter commented on GitHub (Dec 9, 2025): Encountered this as well on v2.31 in docker. I had to fix my DNS to resolve the oidc dns name the error references.
Author
Owner

@Strontium commented on GitHub (Dec 23, 2025):

+1 also seeing this error.
My OIDC provider hostname is also resolved via CNAME.
Used workaround by applying static mapping to IP in docker with extra_hosts, eg:

services:
  audiobookshelf:
    image: ...
    extra_hosts:
      - "auth.domain.com:123.456.789.101"
@Strontium commented on GitHub (Dec 23, 2025): +1 also seeing this error. My OIDC provider hostname is also resolved via CNAME. Used workaround by applying static mapping to IP in docker with extra_hosts, eg: ```yaml services: audiobookshelf: image: ... extra_hosts: - "auth.domain.com:123.456.789.101" ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/audiobookshelf-advplyr#3111
No description provided.