add persistance for auth
This commit is contained in:
parent
8ebf1e044e
commit
18c96302e2
2 changed files with 4 additions and 0 deletions
|
@ -21,6 +21,7 @@
|
||||||
"@solidjs/router": "^0.15.3",
|
"@solidjs/router": "^0.15.3",
|
||||||
"@solidjs/start": "^1.1.4",
|
"@solidjs/start": "^1.1.4",
|
||||||
"better-auth": "^1.2.7",
|
"better-auth": "^1.2.7",
|
||||||
|
"better-sqlite3": "^11.10.0",
|
||||||
"sitemap": "^8.0.0",
|
"sitemap": "^8.0.0",
|
||||||
"solid-icons": "^1.1.0",
|
"solid-icons": "^1.1.0",
|
||||||
"solid-js": "^1.9.6",
|
"solid-js": "^1.9.6",
|
||||||
|
@ -28,6 +29,7 @@
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@testing-library/jest-dom": "^6.6.3",
|
"@testing-library/jest-dom": "^6.6.3",
|
||||||
|
"@types/better-sqlite3": "^7.6.13",
|
||||||
"browserslist": "^4.24.5",
|
"browserslist": "^4.24.5",
|
||||||
"bun-types": "^1.2.13",
|
"bun-types": "^1.2.13",
|
||||||
"lightningcss": "^1.30.1",
|
"lightningcss": "^1.30.1",
|
||||||
|
|
|
@ -2,8 +2,10 @@ import { betterAuth } from "better-auth";
|
||||||
import { genericOAuth } from "better-auth/plugins";
|
import { genericOAuth } from "better-auth/plugins";
|
||||||
import { createAuthClient } from "better-auth/solid";
|
import { createAuthClient } from "better-auth/solid";
|
||||||
import { genericOAuthClient } from "better-auth/client/plugins";
|
import { genericOAuthClient } from "better-auth/client/plugins";
|
||||||
|
import Database from "better-sqlite3";
|
||||||
|
|
||||||
export const auth = betterAuth({
|
export const auth = betterAuth({
|
||||||
|
database: Database('auth.sqlite'),
|
||||||
appName: "Streamarr",
|
appName: "Streamarr",
|
||||||
basePath: "/api/auth",
|
basePath: "/api/auth",
|
||||||
logger: {
|
logger: {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue