-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
128 lines (120 loc) · 3.18 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
version: '3.8'
# Environment for local development
services:
gateway-service:
build:
context: ./gateway-service
dockerfile: gateway-service.Dockerfile
ports:
- "8080:80"
environment:
GATEWAY_PORT: "80"
USER_GRPC_HOST: "user-service"
USER_GRPC_PORT: "50001"
DOCUMENT_GRPC_PORT: "50002"
DOCUMENT_GRPC_HOST: "document-service"
CALENDAR_GRPC_PORT: "50051"
CALENDAR_GRPC_HOST: "calendar-service"
REDIS_HOST: redis
REDIS_PORT: 6379
REDIS_PASSWORD: VWtWRVNWTmZVRUZUVTFkUFVrUQ==
JWT_SECRET: someSecretJwtKey
GIN_MODE: debug
MAILERSEND_API_KEY:
HOST_URL: http://localhost:8080
ENVIRONMENT: development
SENTRY_DSN:
HCAPTCHA_SECRET: 0x0000000000000000000000000000000000000000
networks:
- gateway-network
- redis-network
depends_on:
- redis
user-service:
build:
context: ./user-service
dockerfile: user-service.Dockerfile
environment:
GRPC_PORT: 50001
POSTGRES_HOST: users_postgres
POSTGRES_PORT: 5432
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
POSTGRES_DB: users
SENTRY_DSN:
networks:
- gateway-network
- users-network
depends_on:
- users_postgres
document-service:
build:
context: ./document-service
dockerfile: document-service.Dockerfile
environment:
GRPC_PORT: 50002
POSTGRES_HOST: documents_postgres
POSTGRES_PORT: 5432
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
POSTGRES_DB: documents
ENCRYPTION_KEY: 8dHWTNSAsGaaD7JbqVubF1aWVWGJYF3q
SENTRY_DSN:
networks:
- gateway-network
- documents-network
depends_on:
- documents_postgres
calendar-service:
build:
context: ./calendar-service
dockerfile: calendar-service.Dockerfile
environment:
RUST_BACKTRACE: true
GRPC_PORT: 50051
ENCRYPTION_KEY: f149VI7P9EsUkirKOnGNy9YKQtbZKEAj
volumes:
- ./calendar-service/data/:/data/
networks:
- gateway-network
users_postgres:
image: postgres:14.5-alpine3.16
environment:
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
POSTGRES_DB: users
ports:
- "5432:5432"
volumes:
- ./user-service/db-data/postgres/:/var/lib/postgresql/data
networks:
- users-network
documents_postgres:
image: postgres:14.5-alpine3.16
environment:
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
POSTGRES_DB: documents
networks:
- documents-network
ports:
- "5433:5432"
volumes:
- ./document-service/db-data/postgres/:/var/lib/postgresql/data
- ./document-service/db-data/backup/:/backup
redis:
image: redis:6.2.7-alpine3.16
environment:
REDIS_PASSWORD: VWtWRVNWTmZVRUZUVTFkUFVrUQ==
entrypoint: ["/bin/sh", "-c", "redis-server --appendonly yes --requirepass $${REDIS_PASSWORD} --maxmemory 256mb --maxmemory-policy allkeys-lru"]
networks:
- redis-network
ports:
- "6379:6379"
volumes:
- ./gateway-service/db-data/redis/:/data
networks:
gateway-network:
documents-network:
users-network:
redis-network: