This repository has been archived by the owner on Mar 19, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathdocker-compose.yml
150 lines (140 loc) · 3.27 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
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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
version: '3.8'
services:
rabbitmq:
image: rabbitmq:3.9.7-management
container_name: rabbitmq
ports:
- 5672:5672
- 15672:15672
networks:
- ritta
healthcheck:
test: rabbitmq-diagnostics -q ping
interval: 5s
timeout: 10s
retries: 12
gateway:
image: ghcr.io/rittaschool/ritta:master-gateway
depends_on:
rabbitmq:
condition: service_healthy
environment:
- NODE_ENV=production
- PORT=3000
- RMQ_HOST=rabbitmq
- RMQ_PORT=5672
- RMQ_USERNAME=guest
- RMQ_PASSWORD=guest
- REDIS_URI=redis://gateway-db:6379
- JWT_SIGNING_SECRET=RITTATESTSIGNINGKEY
- FRONTEND_PUBLIC_URL=http://localhost:3002
ports:
- '3000:3000'
networks:
- ritta
auth:
image: ghcr.io/rittaschool/ritta:master-auth
depends_on:
rabbitmq:
condition: service_healthy
environment:
- NODE_ENV=production
- RMQ_HOST=rabbitmq
- RMQ_PORT=5672
- RMQ_USERNAME=guest
- RMQ_PASSWORD=guest
- SIGNING_KEY=RITTATESTSIGNINGKEY
networks:
- ritta
users:
image: ghcr.io/rittaschool/ritta:master-users
depends_on:
rabbitmq:
condition: service_healthy
users_db:
condition: service_healthy
environment:
- NODE_ENV=production
- RMQ_HOST=rabbitmq
- RMQ_PORT=5672
- RMQ_USERNAME=guest
- RMQ_PASSWORD=guest
- MONGO_URI=mongodb://ritta:password@users_db:27017/ritta?authSource=admin
networks:
- ritta
messages:
image: ghcr.io/rittaschool/ritta:master-messages
depends_on:
rabbitmq:
condition: service_healthy
messages_db:
condition: service_healthy
environment:
- NODE_ENV=production
- RMQ_HOST=rabbitmq
- RMQ_PORT=5672
- RMQ_USERNAME=guest
- RMQ_PASSWORD=guest
- MONGO_URI=mongodb://ritta:password@messages_db:27019/ritta?authSource=admin
networks:
- ritta
users_db:
image: mongo:latest
environment:
- MONGO_INITDB_DATABASE=ritta
- MONGO_INITDB_ROOT_USERNAME=ritta
- MONGO_INITDB_ROOT_PASSWORD=password
networks:
- ritta
ports:
- "127.0.0.1:27017:27017"
healthcheck:
test: mongosh --quiet --eval "db.runCommand('ping').ok"
interval: 5s
timeout: 10s
retries: 12
messages_db:
image: mongo:latest
environment:
- MONGO_INITDB_DATABASE=ritta
- MONGO_INITDB_ROOT_USERNAME=ritta
- MONGO_INITDB_ROOT_PASSWORD=password
networks:
- ritta
ports:
- "127.0.0.1:27019:27017"
healthcheck:
test: mongosh --quiet --eval "db.runCommand('ping').ok"
interval: 5s
timeout: 10s
retries: 12
gateway-db:
image: redislabs/rejson:latest
networks:
- ritta
ports:
- "6380:6379"
loki:
image: grafana/loki:2.4.0
ports:
- "3100:3100"
command: -config.file=/etc/loki/local-config.yaml
networks:
- loki
promtail:
image: grafana/promtail:2.4.0
volumes:
- /var/log:/var/log
command: -config.file=/etc/promtail/config.yml
networks:
- loki
grafana:
image: grafana/grafana:latest
ports:
- "3001:3000"
networks:
- loki
networks:
ritta:
driver: bridge
loki: