-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.dev.yml
More file actions
114 lines (107 loc) · 2.77 KB
/
docker-compose.dev.yml
File metadata and controls
114 lines (107 loc) · 2.77 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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
version: '3.8'
services:
# CAM-OS Kernel Development Container
cam-kernel-dev:
build:
context: .
dockerfile: Dockerfile.dev
target: development
image: cam-os/kernel-dev:latest
container_name: cam-kernel-dev
volumes:
- .:/workspace:cached
- go-modules:/go/pkg/mod
command: /bin/sh -c "while sleep 1000; do :; done"
ports:
- "8080:8080" # gRPC API
- "9090:9090" # Metrics
- "2345:2345" # Delve debug port
environment:
- CAM_LOG_LEVEL=debug
- CAM_GRPC_PORT=8080
- CAM_METRICS_PORT=9090
- CAM_REDIS_URL=redis://redis:6379
- CAM_POSTGRES_URL=postgres://cam_user:cam_password@postgres:5432/cam_db
- CAM_DEVELOPMENT=true
depends_on:
- redis
- postgres
networks:
- cam-network
# Redis for context storage and caching
redis:
image: redis:7-alpine
container_name: cam-redis-dev
ports:
- "6379:6379"
volumes:
- redis-data:/data
command: redis-server --appendonly yes --maxmemory 128mb --maxmemory-policy allkeys-lru
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 3
networks:
- cam-network
# PostgreSQL for persistent storage
postgres:
image: postgres:15-alpine
container_name: cam-postgres-dev
ports:
- "5432:5432"
environment:
- POSTGRES_USER=cam_user
- POSTGRES_PASSWORD=cam_password
- POSTGRES_DB=cam_db
volumes:
- postgres-data:/var/lib/postgresql/data
- ./scripts/init-db-dev.sql:/docker-entrypoint-initdb.d/init-db.sql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U cam_user -d cam_db"]
interval: 10s
timeout: 5s
retries: 3
networks:
- cam-network
# Development Driver Runtime
driver-runtime-dev:
image: cam-os/driver-runtime-dev:latest
container_name: cam-driver-runtime-dev
ports:
- "8081:8081"
environment:
- CAM_KERNEL_URL=cam-kernel-dev:8080
- CAM_DRIVER_PORT=8081
- CAM_DEVELOPMENT=true
volumes:
- ./drivers:/app/drivers:ro
networks:
- cam-network
depends_on:
- cam-kernel-dev
# Prometheus for development metrics
prometheus-dev:
image: prom/prometheus:v2.45.0
container_name: cam-prometheus-dev
ports:
- "9091:9090"
volumes:
- ./monitoring/prometheus/prometheus-dev.yml:/etc/prometheus/prometheus.yml
- prometheus-data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.enable-lifecycle'
networks:
- cam-network
depends_on:
- cam-kernel-dev
volumes:
go-modules:
redis-data:
postgres-data:
prometheus-data:
networks:
cam-network:
driver: bridge