-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
66 lines (65 loc) · 1.56 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
59
60
61
62
63
64
65
66
version: '3.8'
services:
backend:
image: donations-tracker-backend:latest
restart: unless-stopped
build:
context: ./backend
dockerfile: Dockerfile.local
container_name: donations-tracker-backend
environment:
CONNECTION_STRING: mongodb://donations-tracker-db:27017/dev
CLIENT_ORIGIN: ${FRONTEND_URL}
SESSION_SECRET: top secret
PORT: 8081
DEBUG: backend:*
GOOGLE_GEOCODE_API_KEY: ${GOOGLE_GEOCODE_API_KEY}
RESEND_API_KEY: ${RESEND_API_KEY}
RESEND_EMAIL_FROM: ${RESEND_EMAIL_FROM}
FRONTEND_URL: ${FRONTEND_URL}
BACKEND_URL: ${BACKEND_URL}
ports:
- 8081:8081
networks:
- tracker
volumes:
- "/backend/node_modules/"
- "./backend:/backend"
depends_on:
- db
frontend:
image: donations-tracker-frontend:latest
restart: unless-stopped
build:
context: ./frontend
dockerfile: Dockerfile.local
args:
VITE_GOOGLE_MAPS_API_KEY: ${VITE_GOOGLE_MAPS_API_KEY}
VITE_GOOGLE_MAP_ID: ${VITE_GOOGLE_MAP_ID}
VITE_API_URL: ${VITE_API_URL}
container_name: donations-tracker-frontend
environment:
PORT: 8080
ports:
- 8080:8080
networks:
- tracker
volumes:
- "/app/node_modules/"
- "./frontend:/app"
db:
image: mongo:latest
restart: unless-stopped
ports:
- 27017:27017
container_name: donations-tracker-db
networks:
- tracker
volumes:
- mongo-data:/data/db
networks:
tracker:
driver: bridge
volumes:
mongo-data:
driver: local