Open ossmate opened 4 years ago
I am having the same issue, same code and also using setupProxy.js
I did remove the changeOrigin and it works. cheers
I did remove the changeOrigin and it works. cheers
hmm, true we will see if it's worky only for 5 min or more
I'm having the same issue. For some reason it will not redirect back even after taking out change origin. @Miquelllabres would you mind sharing your code.
I'm also having the same issue.It would be great if anyone could suggest what can be done to solve this. Removing change Origin didn't worked out for me.
Please, try this:
const proxy = require("http-proxy-middleware");
module.exports = function (app) {
app.use(proxy("/auth/google", { target: "http://localhost:5000/" }));
app.use(proxy("/api/*", { target: "http://localhost:5000/" }));
};
In your Google auth profile change callback URL to http://localhost:3000/auth/google/callback
After loggin to app it redirect to localhost:5000/surveys instead of localhost:3000/surveys
authRoutes.js
setupProxy.js -> instead of proxy in package.json
console identification URI
http://localhost:5000
http://localhost:3000
autorizated URI
http://localhost:5000/auth/google/callback
http://localhost:3000/auth/google/callback
I just simply get error
Cannot GET /surveys
and browser URL ishttp://localhost:5000/surveys