Routes /cas/login and /cas/logout
This commit is contained in:
parent
28938b679b
commit
0738cddcd6
3 changed files with 42 additions and 6 deletions
|
|
@ -324,6 +324,14 @@ async function createApp(appType) {
|
|||
app.use('/rest', reportsRest);
|
||||
}
|
||||
install404Fallback('/rest');
|
||||
if (config.cas && config.cas.enabled === true) {
|
||||
app.get('/cas/login',
|
||||
passport.authenticateCas,
|
||||
function(req, res) {
|
||||
res.redirect('/?cas-login-success');
|
||||
});
|
||||
app.get('/cas/logout', passport.logoutCas);
|
||||
}
|
||||
}
|
||||
|
||||
app.use('/', await index.getRouter(appType));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue