- Add MinIO service to compose.yaml with named volume - Add generic /api/uploads POST+GET route with auth, 5 MB, image/* guards - Add src/lib/minio.ts singleton client with ensureBucket helper - Add garden Drizzle schema: containers, plants, care_logs, care_schedules, species_cache - Register garden module in src/modules/index.ts and src/lib/db.ts - Apply migration 0015_garden_schema.sql - Add MINIO_* and PERENUAL_API_KEY to .env.example - Add task briefs 70-75 for the full garden feature arc - Add uploads.spec.ts E2E test (RED → GREEN on route auth guard)
20 lines
584 B
TypeScript
20 lines
584 B
TypeScript
import { drizzle } from "drizzle-orm/postgres-js";
|
|
import postgres from "postgres";
|
|
import * as coreSchema from "@/modules/_core/schema";
|
|
import * as calendarSchema from "@/modules/calendar/schema";
|
|
import * as listsSchema from "@/modules/lists/schema";
|
|
import * as notesSchema from "@/modules/notes/schema";
|
|
import * as gardenSchema from "@/modules/garden/schema";
|
|
|
|
const client = postgres(process.env["DATABASE_URL"]!);
|
|
|
|
const schema = {
|
|
...coreSchema,
|
|
...calendarSchema,
|
|
...listsSchema,
|
|
...notesSchema,
|
|
...gardenSchema,
|
|
};
|
|
|
|
export const db = drizzle(client, { schema });
|