From 6a6c786f2c9351736b3b460b3b4df46f240144d3 Mon Sep 17 00:00:00 2001 From: JosuerBague Date: Mon, 18 Dec 2023 16:46:31 +0800 Subject: [PATCH] thjs-64: * Readme + commands --- readme.md | 4 ++-- server/.env.example | 3 +++ server/package.json | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/readme.md b/readme.md index d5463c70..3c1e547e 100644 --- a/readme.md +++ b/readme.md @@ -117,7 +117,7 @@ The main frameworks and libraries used in the project are listed here. A complet 3. Run [migrations](https://knexjs.org/#Migrations) and seeds to populate the database with demo data. To do this, in the command line (terminal) in the server folder, run: ``` - npm run migrate:run + npm run migrate:dev npm run seed:run ``` @@ -126,7 +126,7 @@ The main frameworks and libraries used in the project are listed here. A complet 4. To start the server in the command line (terminal) in the server folder, run: ``` - npm start + npm start:dev ``` 5. To test the correct completing the task in the command line (terminal) in the server folder, run: diff --git a/server/.env.example b/server/.env.example index 8b2baa4d..2c7e5f0b 100644 --- a/server/.env.example +++ b/server/.env.example @@ -2,6 +2,7 @@ # APPLICATION # # APP_PORT - default. own preference might be used +APP_HOST=localhost APP_PORT=3001 NODE_ENV=development @@ -21,6 +22,8 @@ DB_PASSWORD=postgres DB_HOST=localhost DB_PORT=5432 DB_CLIENT=pg +DB_POOL_MIN=1 +DB_POOL_MAX=10 # # AUTHENTICATION diff --git a/server/package.json b/server/package.json index 74b075d9..639e34d0 100644 --- a/server/package.json +++ b/server/package.json @@ -19,7 +19,7 @@ "lint:js": "npx eslint --ext .ts src", "lint": "npm run lint:js", "build": "tsc && tsc-alias", - "pretest": "cross-env NODE_ENV=test npm run migrate:run", + "pretest": "cross-env NODE_ENV=test npm run migrate:dev", "test": "cross-env NODE_ENV=test node --experimental-vm-modules --expose-gc --no-compilation-cache ../node_modules/jest/bin/jest.js --runInBand", "test:starter": "npm run test -- --verbose --rootDir=tests/api/0-starter/", "test:dislike-post": "npm run test -- --verbose --rootDir=tests/api/1-dislike-post/",