Share feedback, ideas and get community help

Updated 10 months ago

Odd Error running locally maybe IPv6?

At a glance

The community member is experiencing an error when trying to make a web HTTP call locally, with a TypeError: fetch failed error. The comments suggest that the issue may be related to running the application in a rootless container using PODMAN, which can cause networking issues outside the container. A community member suggests that creating a rootless network or running the containers as root may resolve the issue. The comments indicate that this is a limitation of running in a rootless container, rather than a bug.

I was trying to make a web HTTP call. I am running everything local and I seen this error when trying to fetch a url. Any ideas?
Plain Text
TypeError: fetch failed
    at node:internal/deps/undici/undici:12618:11
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async function_ (file:///app/node_modules/.pnpm/ky@1.2.3/node_modules/ky/distribution/core/Ky.js:18:28)
    at async T (/app/apps/viewer/.next/server/chunks/77.js:1:2536)
    at async E (/app/apps/viewer/.next/server/chunks/77.js:1:1183)
    at async /app/apps/viewer/.next/server/pages/api/[...trpc].js:82:16636
    at async x (/app/apps/viewer/.next/server/pages/api/[...trpc].js:82:13780)
    at async O (/app/apps/viewer/.next/server/pages/api/[...trpc].js:86:200415)
    at async u (/app/apps/viewer/.next/server/pages/api/[...trpc].js:30:25108)
�    at async resolveMiddleware (file:///app/node_modules/.pnpm/@trpc+server@10.40.0/node_modules/@trpc/server/dist/index.mjs:420:30) {
  cause: Error: connect ECONNREFUSED ::1:11434
      at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1555:16) {
    errno: -111,
    code: 'ECONNREFUSED',
    syscall: 'connect',
    address: '::1',
    port: 11434
  }
}
B
C
4 comments
Fetch which URL?
Can you provide more details on what you do to trigger that error?
I think i fugured it out. You see if you use PODMAN to run this stack its running the main container rootless. Means it has no authority over the host system that to include networking outside the container. You just have to create a rootless network or simply allow your containers to run as root. I got around it by using netavark some built in library. Sorry I dident update this
Not a bug just a limitation of a rootless container 🙂
Add a reply
Sign up and join the conversation on Discord