From 671fa7a401a68237a0c6920dc509b69129cff831 Mon Sep 17 00:00:00 2001 From: Aidan Date: Mon, 3 Mar 2025 21:35:34 -0500 Subject: [PATCH] docs: add database schema update instructions to README --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index e54a01b..8e576b7 100644 --- a/README.md +++ b/README.md @@ -186,6 +186,17 @@ We suggest starting by allowing Auth.js | AUTH_TRUST_HOST | Required, should always be set to `true` | `true` | | NEXTAUTH_URL | The URL LibreCloud will be publicly accessible at | `http://localhost:3000` (testing), `https://example.com` (production) | +## Database schema updates + +In case of an update to `prisma/schema.prisma`, you should run the below command to migrate the old database. + +Each update to this file is guaranteed to work with the previous version of the file to ensure maximum compatibility. While every effort has been made to ensure compatibility, we are not responsible for any data loss. + +```bash +npx prisma migrate dev --name update-schema # Migrate +npx prisma migrate deploy # Deploy +``` + ## To-Do * [X] Add documentation on .env