-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
30 lines (29 loc) · 844 Bytes
/
docker-compose.yml
File metadata and controls
30 lines (29 loc) · 844 Bytes
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
services:
controlaestoque.database:
image: mysql:8.0.40
container_name: controlaestoque.database
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${MYSQL_DATABASE}
volumes:
- "./.containers/controlaestoque-db:/var/lib/mysql"
ports:
- "3308:3306"
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
timeout: 20s
retries: 10
controlaestoque.api:
image: ${DOCKER_REGISTRY-}controlaestoqueapi
container_name: controlaestoque.api
environment:
ConnectionStrings__MYSQL_DB_CONNECTION: ${MYSQL_CONNECTION_STRING}
build:
context: .
dockerfile: src/ControlaEstoque.API/Dockerfile
ports:
- "5000:5000"
- "5001:5001"
depends_on:
- controlaestoque.database
restart: on-failure