-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
47 lines (40 loc) · 918 Bytes
/
docker-compose.yml
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
version: '3'
services:
db:
image: mysql:8.0
restart: always
environment:
MYSQL_ROOT_PASSWORD: 12345678
MYSQL_DATABASE: mydatabasePortfolio
ports:
- '3307:3306'
volumes:
- db:/var/lib/mysql
networks:
- app-network
api:
build:
context: .
dockerfile: Dockerfile
ports:
- "8080:8080"
environment:
- ConnectionStrings:DefaultConnection=Server=host.docker.internal;Port=3307;Database=mydatabasePortfolio;User=root;Password=12345678;
depends_on:
- db
volumes:
db:
networks:
app-network:
# version: '3'
# services:
# api:
# build:
# context: .
# dockerfile: Dockerfile
# ports:
# - "8080:8080"
# environment:
# - ConnectionStrings:DefaultConnection=Server=host.docker.internal;Port=3306;Database=mydatabasePortfolio;User=root;Password=12345678;
# networks:
# app-network: