forked from TEAMPICKL/PICKL_BE
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
84 lines (78 loc) · 2.24 KB
/
docker-compose.yml
File metadata and controls
84 lines (78 loc) · 2.24 KB
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
services:
app:
image: ${DOCKER_USERNAME}/${DOCKER_REPO}:latest
ports:
- "8080:8080"
environment:
- SPRING_PROFILES_ACTIVE=${SPRING_PROFILES_ACTIVE}
- SPRING_DATASOURCE_URL=jdbc:mysql://mysql:3306/pickl?useUnicode=true&characterEncoding=utf8&connectionCollation=utf8mb4_unicode_ci&serverTimezone=Asia/Seoul&allowPublicKeyRetrieval=true&useSSL=false
- SPRING_DATASOURCE_USERNAME=root
- SPRING_DATASOURCE_PASSWORD=${SPRING_DATASOURCE_PASSWORD}
- SPRING_JPA_HIBERNATE_DDL_AUTO=update
- SPRING_FLYWAY_ENABLED=false
command:
- java -Dspring.profiles.active=${SPRING_PROFILES_ACTIVE} -jar app.jar
depends_on:
mysql:
condition: service_healthy
langchain:
condition: service_healthy
networks:
- pickl-network
langchain:
image: ${DOCKER_USERNAME}/${CHATBOT_REPO}:${CHATBOT_TAG:-latest}
env_file: .env
command: [ "uvicorn","app.main:app","--host","0.0.0.0","--port","8000" ] # ← 추가
healthcheck:
test: [ "CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')" ]
interval: 10s
timeout: 5s
retries: 5
networks:
- pickl-network
mysql:
image: mysql:8.0
ports:
- "3306:3306"
environment:
- MYSQL_DATABASE=pickl
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
volumes:
- mysql-data:/var/lib/mysql
healthcheck:
test: [ "CMD", "mysqladmin", "ping", "-h", "localhost" ]
interval: 10s
timeout: 5s
retries: 5
networks:
- pickl-network
nginx:
container_name: nginx-container
image: nginx:latest
ports:
- "80:80"
- "443:443"
volumes:
- /home/ubuntu/nginx/conf.d:/etc/nginx/conf.d
- /etc/letsencrypt:/etc/letsencrypt:ro
depends_on:
- app
networks:
- pickl-network
dozzle:
image: amir20/dozzle:latest
container_name: dozzle
restart: unless-stopped
environment:
- DOZZLE_BASE=/dozzle
- DOZZLE_AUTH_PROVIDER=simple
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./dozzle/users.yml:/data/users.yml:ro
networks:
- pickl-network
networks:
pickl-network:
driver: bridge
volumes:
mysql-data: