Skip to content

Commit 9243805

Browse files
committed
Added docker
1 parent 7a18fc7 commit 9243805

File tree

4 files changed

+20
-1
lines changed

4 files changed

+20
-1
lines changed

.dockerignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Dockerfile
2+
node_modules
3+
dist

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ out-tsc
88
# dependencies
99
node_modules
1010

11+
# db
12+
mysql
13+
1114
# IDEs and editors
1215
/.idea
1316
.project

apps/car-rental-backend/src/app/app.module.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { TypeOrmModule } from '@nestjs/typeorm';
1010
host: 'localhost',
1111
port: 3306,
1212
username: 'root',
13-
password: 'password',
13+
password: 'root',
1414
database: 'car_rental',
1515
entities: [],
1616
synchronize: true,

docker-compose.yml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: '3.8'
2+
3+
services:
4+
db:
5+
image: mysql:5.7
6+
restart: always
7+
environment:
8+
MYSQL_ROOT_PASSWORD: root
9+
MYSQL_DATABASE: car_rental
10+
ports:
11+
- "3306:3306"
12+
volumes:
13+
- ./mysql:/var/lib/mysql

0 commit comments

Comments
 (0)