Dify cross domain problem #32571
Replies: 1 comment
-
|
Hi @worldpathbreaker! I'm Dosu and I’m helping the dify team. This is a SameSite cookie issue, not just a CORS problem. Dify sets cookies with To fix this, configure your backend WEB_API_CORS_ALLOW_ORIGINS=http://192.168.1.188:3000,*
CONSOLE_CORS_ALLOW_ORIGINS=http://192.168.1.188:3000,*
CONSOLE_API_URL=http://192.168.1.217:5001
CONSOLE_WEB_URL=http://192.168.1.188:3000
COOKIE_DOMAIN=Critical: Leave And configure your frontend NEXT_PUBLIC_API_PREFIX=http://192.168.1.217:5001/console/api
NEXT_PUBLIC_PUBLIC_API_PREFIX=http://192.168.1.217:5001/apiAfter making changes, clear your browser cookies and restart both services. Better long-term solution: Use HTTPS for both frontend and backend (self-signed certificates work for local dev). This allows secure cookie handling for cross-origin setups. To reply, just mention @dosu. How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Self Checks
Content
Beta Was this translation helpful? Give feedback.
All reactions