mirror of
https://github.com/catdevnull/preciazo.git
synced 2024-11-29 21:16:19 +00:00
migrar BD cuando se corre el sitio
This commit is contained in:
parent
c52ed1d569
commit
1214aa5fbe
1 changed files with 1 additions and 9 deletions
|
@ -1,10 +1,2 @@
|
||||||
import Database from "better-sqlite3";
|
export { db } from "db-datos/db.js";
|
||||||
import { drizzle } from "drizzle-orm/better-sqlite3";
|
|
||||||
import * as schema from "db-datos/schema.js";
|
|
||||||
import { env } from "$env/dynamic/private";
|
|
||||||
|
|
||||||
const sqlite = new Database(env.DB_PATH ?? "../scraper/sqlite.db");
|
|
||||||
const db = drizzle(sqlite, { schema });
|
|
||||||
|
|
||||||
export { db };
|
|
||||||
export * as schema from "db-datos/schema.js";
|
export * as schema from "db-datos/schema.js";
|
||||||
|
|
Loading…
Reference in a new issue