added prefix config
This commit is contained in:
parent
a7ec0e3cde
commit
3f258bcd33
4 changed files with 12 additions and 13 deletions
19
README.md
19
README.md
|
|
@ -1,4 +1,4 @@
|
|||
# common-cents-api
|
||||
# Common Cents API
|
||||
REST API for expense tracking and budgeting.
|
||||
|
||||
## Project setup
|
||||
|
|
@ -14,9 +14,11 @@ Start the API:
|
|||
```bash
|
||||
npm run start:dev
|
||||
```
|
||||
Verify running via the [healthcheck](http://localhost:3000/common-cents/health) endpoint.
|
||||
Verify running via the [healthcheck](http://localhost:3000/common-cents/healthcheck) endpoint.
|
||||
|
||||
Default port (`3000`) can be changed by setting the `PORT=xxxx` environment variable.
|
||||
Default port (`3000`) can be changed by setting the `PORT=` environment variable.
|
||||
|
||||
Default prefix (`common-cents`) can be changed by setting the `PREFIX=` environment variable.
|
||||
|
||||
### Database
|
||||
Supported configurations:
|
||||
|
|
@ -35,14 +37,11 @@ For external Postgres, configure additional environment variables. To simplify t
|
|||
```text
|
||||
# .env
|
||||
|
||||
# API port
|
||||
# API Config
|
||||
PORT=3000
|
||||
|
||||
# Either 'sqlite' or 'postgres' (if not set sqlite will be used)
|
||||
DB_TYPE=sqlite
|
||||
|
||||
# Sync should be false for production
|
||||
DB_SYNC=true
|
||||
PREFIX=common-cents
|
||||
DB_TYPE=sqlite # 'sqlite' or 'postgres'
|
||||
DB_SYNC=true # Sync should be false for production
|
||||
|
||||
# Postgres overrides
|
||||
PG_HOST=localhost
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue