-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
54 lines (50 loc) · 1.07 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
version: "3.10"
services:
frontend:
build: frontend
ports:
- 8501:8501
networks:
Connection_service:
aliases:
- frontend.docker
depends_on:
- backend
- postgres
volumes:
- ./frontend:/app
backend:
build: backend
ports:
- 8000:8000
networks:
Connection_service:
aliases:
- backend.docker
volumes:
- ./backend:/app
postgres:
container_name: postgres
image: 'postgres:latest'
restart: always
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=experiment_db
logging:
options:
max-size: 10m
max-file: "3"
ports:
- 5432:5432
networks:
Connection_service:
aliases:
- postgres.docker
volumes:
# copy the sql script to create tables
- ./sql/create_experiment_table.sql:/docker-entrypoint-initdb.d/create_experiment_table.sql
- ./postgres_data:/var/lib/postgresql/postgres_data
networks:
Connection_service:
external: false