forked from administration/panel
21 lines
499 B
TypeScript
21 lines
499 B
TypeScript
import type { AuthOptions } from "next-auth";
|
|
import AuthentikProvider from "next-auth/providers/authentik";
|
|
|
|
export const authOptions: AuthOptions = {
|
|
providers: [
|
|
AuthentikProvider({
|
|
clientId: process.env.AUTHENTIK_ID!,
|
|
clientSecret: process.env.AUTHENTIK_SECRET!,
|
|
issuer:
|
|
process.env.AUTHENTIK_ISSUER ??
|
|
"https://sso.revolt.chat/application/o/admin-panel",
|
|
}),
|
|
],
|
|
jwt: {
|
|
maxAge: 2 * 60 * 60, // 2 hours
|
|
},
|
|
pages: {
|
|
signIn: "/",
|
|
},
|
|
};
|