medusajs / nextjs-starter-medusa

A performant frontend ecommerce starter template with Next.js 14 and Medusa.
https://next.medusajs.com/
MIT License
1.78k stars 495 forks source link

TypeError: fetch failed src\middleware.ts (21:30) @ fetch #314

Closed oulfr closed 7 months ago

oulfr commented 7 months ago

The backend is functioning without issue, but when I run the storefront at http://localhost:8000/, I encounter the following error with a fresh installation:

       TypeError: Fetch failed src\middleware.ts (21:30) @ fetch

       node -v:
       v21.6.0
oulfr commented 7 months ago

Okay, I found that the address of the backend, http://localhost:9000, is resolved, but not http://127.0.0.1:9000 due to proxy settings. I'm using DNS resolution for the backend, and it works great.