You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Server: Express.JS REST API with JWT authentication.
Client: Next.JS app that uses Axios to talk with the server.
I tested it on localhost with Docker Compose: Everything working fine (both Postman and the browser successfully store the token as a cookie to use on subsequent requests.).
I deployed it to Google Cloud Run (one service for each container). Everything working fine except that now only requests made through Postman are storing the token as a cookie.
The browser (the Next.JS app) no longer does the same, even though the request returns a successful response there is no token in the browser cookies.
I did some research, found a few similar problems, and the solutions usually involve setting up some CORS configurations, so I updated my code by adding these configurations, but the issue remains.
2 Docker containers:
I tested it on localhost with Docker Compose: Everything working fine (both Postman and the browser successfully store the token as a cookie to use on subsequent requests.).
I deployed it to Google Cloud Run (one service for each container). Everything working fine except that now only requests made through Postman are storing the token as a cookie.
The browser (the Next.JS app) no longer does the same, even though the request returns a successful response there is no token in the browser cookies.
I did some research, found a few similar problems, and the solutions usually involve setting up some CORS configurations, so I updated my code by adding these configurations, but the issue remains.
I am currently trying it like this:
Server-side:
Client-side:
The text was updated successfully, but these errors were encountered: