-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Open
Description
After loggin to app it redirect to localhost:5000/surveys instead of localhost:3000/surveys
authRoutes.js
app.get(
'/auth/google/callback',
passport.authenticate('google'),
(req, res) => {
res.redirect('/surveys');
}
);
setupProxy.js -> instead of proxy in package.json
const { createProxyMiddleware } = require('http-proxy-middleware');
module.exports = function(app) {
app.use(
'/auth/google',
createProxyMiddleware({
target: 'http://localhost:5000',
changeOrigin: true,
})
);
app.use(
'/api/*',
createProxyMiddleware({
target: 'http://localhost:5000',
changeOrigin: true,
})
);
};
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 is http://localhost:5000/surveys
Metadata
Metadata
Assignees
Labels
No labels