Vendor SharedCode locally
This commit is contained in:
1 parent
a8c51b8484
commit
6eb8f4ad60
88 files changed
+9708
-275
No files matched your search
@@ -0,0 +1,20 @@
|
||||
# `@gabriel20xx/node-backend`
|
||||
|
||||
Shared Node.js backend infrastructure for services that use PostgreSQL:
|
||||
|
||||
- validated `DATABASE_URL` and pool settings;
|
||||
- one pool owner with startup retry, transient query retry, transactions, and shutdown;
|
||||
- PBKDF2 password hashing and secure session-token helpers;
|
||||
- short-lived, one-time admin reset codes printed to the server console;
|
||||
- common account/session persistence;
|
||||
- transaction-locked ordered migrations.
|
||||
|
||||
The package does not depend on Express. Each service keeps its own routes,
|
||||
cookies, roles, validation policy, and domain repositories. Existing
|
||||
`MediaShared` code can be migrated into this package incrementally; keep the
|
||||
legacy package as a compatibility layer until every consumer has moved.
|
||||
|
||||
Pass a service-specific `tableName` to `runMigrations` when multiple services
|
||||
share one PostgreSQL database, so their migration histories cannot collide.
|
||||
|
||||
Run `npm test` from this package or `npm run test --workspace=@gabriel20xx/node-backend` from `SharedCode`.
|
||||
Reference in new issue
Block a user