feat: update auth
This commit is contained in:
@@ -17,7 +17,7 @@ function App() {
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const loadMe = async () => {
|
const loadMe = async () => {
|
||||||
try {
|
try {
|
||||||
const response = await fetch(`/api/me`, {
|
const response = await fetch(`/auth/me`, {
|
||||||
credentials: 'include',
|
credentials: 'include',
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,9 @@ const oidcConfig = {
|
|||||||
response_type: 'code',
|
response_type: 'code',
|
||||||
scope: process.env.OIDC_SCOPE ?? 'openid profile email offline_access',
|
scope: process.env.OIDC_SCOPE ?? 'openid profile email offline_access',
|
||||||
},
|
},
|
||||||
|
routes: {
|
||||||
|
callback: process.env.OIDC_REDIRECT_URL
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
if (!disableAuth && (!oidcConfig.clientID || !oidcConfig.issuerBaseURL || !oidcConfig.clientSecret)) {
|
if (!disableAuth && (!oidcConfig.clientID || !oidcConfig.issuerBaseURL || !oidcConfig.clientSecret)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user