-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
64 lines (59 loc) · 1.53 KB
/
docker-compose.yml
File metadata and controls
64 lines (59 loc) · 1.53 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
version: '3.8'
services:
data-analysis:
build:
context: .
dockerfile: Dockerfile
container_name: data-analysis-workspace
ports:
- "8888:8888" # Jupyter Lab
- "8787:8787" # RStudio Server
- "8080:8080" # Alternative port for web apps
volumes:
# Mount source code for development
- ./src:/app/src
- ./notebooks:/app/notebooks
- ./data:/app/data
- ./configs:/app/configs
- ./outputs:/app/outputs
- ./tests:/app/tests
- ./docs:/app/docs
environment:
- JUPYTER_ENABLE_LAB=yes
- JUPYTER_TOKEN=
- PYTHONPATH=/app/src
working_dir: /app
command: jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' --NotebookApp.password=''
networks:
- data-network
# Optional: PostgreSQL database for data storage
postgres:
image: postgres:15-alpine
container_name: data-analysis-db
environment:
POSTGRES_DB: analysis_db
POSTGRES_USER: analyst
POSTGRES_PASSWORD: analyst_password
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./docker/init-db:/docker-entrypoint-initdb.d
networks:
- data-network
# Optional: Redis for caching and session storage
redis:
image: redis:7-alpine
container_name: data-analysis-cache
ports:
- "6379:6379"
volumes:
- redis_data:/data
networks:
- data-network
volumes:
postgres_data:
redis_data:
networks:
data-network:
driver: bridge