Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ node_modules/
/dist-types
*.tsbuildinfo
dist/

# Persisted local dev backend database (better-sqlite3)
/.data/
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,3 +95,10 @@ yarn install
yarn workspace @rwdocs/backstage-plugin-rw run build
yarn workspace @rwdocs/backstage-plugin-rw-backend run build
```

Run the dev harness (frontend + backend) with `yarn dev`.

The backend persists its SQLite database (catalog, search index, …) under a
`.data/` directory at the repo root, so state survives restarts instead of being
rebuilt from scratch each time. The directory is git-ignored. Delete it
(`rm -rf .data`) for a clean database.
8 changes: 7 additions & 1 deletion app-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@ backend:
dangerouslyDisableDefaultAuthPolicy: true
database:
client: better-sqlite3
connection: ':memory:'
connection:
# Persist the dev DB between runs (catalog, search index, …) instead of
# rebuilding from scratch on every start. Resolved relative to the backend
# process cwd (packages/backend), so ../../ points at the repo root.
# Backstage writes one <pluginId>.sqlite file per plugin in this directory.
# Remove the directory (rm -rf .data) for a clean database.
directory: ../../.data
cors:
origin: http://localhost:3000
credentials: true
Expand Down