mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-12 08:45:38 +02:00
feat: Push schema to remote db
This commit is contained in:
@@ -1,19 +1,12 @@
|
|||||||
import { Resource } from "sst";
|
import { Resource } from "sst";
|
||||||
import { defineConfig } from "drizzle-kit";
|
import { defineConfig } from "drizzle-kit";
|
||||||
|
|
||||||
const connection = {
|
|
||||||
user: Resource.Database.user,
|
|
||||||
password: Resource.Database.password,
|
|
||||||
host: Resource.Database.host,
|
|
||||||
};
|
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
verbose: true,
|
verbose: true,
|
||||||
strict: true,
|
|
||||||
out: "./migrations",
|
out: "./migrations",
|
||||||
dialect: "postgresql",
|
dialect: "postgresql",
|
||||||
dbCredentials: {
|
dbCredentials: {
|
||||||
url: `postgres://${connection.user}:${connection.password}@${connection.host}/nestri`,
|
url: `postgres://${Resource.Database.user}:${Resource.Database.password}@${Resource.Database.host}/${Resource.Database.name}?sslmode=require`,
|
||||||
},
|
},
|
||||||
schema: "./src/**/*.sql.ts",
|
schema: "./src/**/*.sql.ts",
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user