Skip to content

Commit 5a5cc98

Browse files
committed
docs: clarify migration instructions and add note on ClickHouse unique constraints
1 parent 9f0e7ab commit 5a5cc98

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

adminforth/commands/createApp/templates/readme.md.hbs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@ The generated app will seed the default `adminforth` / `adminforth` user on firs
1515
{{/if}}
1616

1717
{{#if prismaDbUrl}}
18-
Migrate the database:
18+
Create the initial migration and apply it to the database:
1919

2020
```bash
21+
{{packageManagerRun}} makemigration{{packageManagerScriptArgSeparator}}--name init
2122
{{packageManagerRun}} migrate:local
2223
```
2324
{{/if}}

adminforth/commands/createApp/utils.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,9 @@ CREATE TABLE adminuser (
111111
)
112112
ENGINE = MergeTree()
113113
ORDER BY id;
114-
\`\`\``;
114+
\`\`\`
115+
116+
ClickHouse does not enforce UNIQUE constraints like PostgreSQL, MySQL, or SQLite. AdminForth authentication expects `email` values in `adminuser` to be unique, so enforce this in your ingestion/application logic and remove duplicate email rows to avoid ambiguous logins.`;
115117
}
116118

117119
if (provider === 'mongodb') {

0 commit comments

Comments
 (0)