File size: 834 Bytes
88f437e
 
 
 
 
 
3cdf53d
 
88f437e
 
 
 
3cdf53d
 
c114c72
3cdf53d
 
 
 
8b7e5fc
3cdf53d
88f437e
 
 
 
 
 
 
 
 
 
8b7e5fc
88f437e
8b7e5fc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
## Description

[Nest](https://github.com/nestjs/nest) framework TypeScript starter repository.

## Project setup

#### 1. Install all dependencies

```bash
$ npm install
```

#### 2. Initialize database

- Download and install `postgreSQL`.
- Create schema name `pbl6` or whatever.

#### 3. Create .env file

- Copy from `.env.example` and fill

## Compile and run the project

```bash
# development
$ npm run start

# watch mode
$ npm run start:dev
```

## In product:

## Notice

```bash
# generate migrations
$ npm run db:migrate:generate src/migrations/NameOfMigrations

# update database follow migrations
$ npm run db:migrate:up

# down database follow migrations
$ npm run db:migrate:down

# Generate resource (include module, controller, service) and moving them to modules
$ npx nest g resource modules/<resource_name>

```