-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
59 lines (54 loc) · 1.3 KB
/
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
48
49
50
51
52
53
54
55
56
57
58
services:
db-carol:
image: mysql:5.7
restart: always
environment:
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
volumes:
# Change to an empty volume in prod
- ./data:/var/lib/mysql
- ./backend/mycustom.cnf:/etc/mysql/conf.d/custom.cnf
# Adicione os scripts SQL dos dois bancos
- ./mysql_v1/wworan_carol_v1.sql:/docker-entrypoint-initdb.d/v1.sql
- ./mysql_v2/wworan_carol_v2.sql:/docker-entrypoint-initdb.d/v2.sql
networks:
- carol-network
- appsmith-network
- cloudbeaver
ports:
- 33061:3306
api:
build: ./backend
restart: always
environment:
SQL_ALCHEMY_CONN: mysql+pymysql://${MYSQL_USER}:${MYSQL_PASSWORD}@db-carol/carol_v1_db
volumes:
- ./backend:/app
ports:
- 8009:5000
depends_on:
- db-carol
networks:
- carol-network
nginx:
restart: always
build:
context: .
dockerfile: ./frontend/Dockerfile
volumes:
- ./nginx.conf:/etc/nginx/conf.d/default.conf
ports:
- ${NGINX_PORT}:80
depends_on:
- api
networks:
- carol-network
networks:
appsmith-network:
external: true
cloudbeaver:
external: true
carol-network:
driver: bridge