forked from fedora-copr/copr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
178 lines (162 loc) · 3.64 KB
/
docker-compose.yaml
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
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
# Port-layout
# ===========
#
# Rootless podman-compose doesn't allow us to start multiple containers in one
# pod that listen on the same port. Therefore we start httpd servers on ports
# (host:pod):
# 5000:5000 -- Frontend Apache (API/WebUI)
# 5001:5001 -- DistGit Apache
# 5002:5002 -- Backend Nginx
# --:5003 -- Keygen Apache (obtaining keys)
#
# Other ports:
# 5009:5432 -- PostgreSQL database
version: '3'
services:
# @TODO Probably not all backend services should use the same Dockerfile
backend-log:
build:
context: docker/backend
hostname: backend-log
command: "/usr/bin/copr_run_logger.py"
depends_on:
- redis
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- results:/var/lib/copr/public_html/results:z
backend-build:
build:
context: docker/backend
hostname: backend-build
command: ["/run-backend", "--sign-host", "keygen-signd", "/usr/bin/copr-run-dispatcher", "builds"]
depends_on:
- backend-log
- resalloc
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- results:/var/lib/copr/public_html/results:z
backend-action:
build:
context: docker/backend
hostname: backend-action
command: ["/run-backend", "--sign-host", "keygen-signd", "/usr/bin/copr-run-dispatcher", "actions"]
depends_on:
- backend-log
- resalloc
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- results:/var/lib/copr/public_html/results:z
resalloc:
build:
context: docker/resalloc
hostname: resalloc
depends_on:
- database
command: /usr/bin/resalloc-server
stdin_open: true
tty: true
redis:
image: centos/redis-32-centos7
hostname: redis
volumes:
- redis:/var/lib/redis/data
backend_httpd:
build:
context: docker/backend_httpd
depends_on:
- backend-log
hostname: backend_httpd
ports:
- "5002:5002"
volumes:
- results:/var/lib/copr/public_html/results:z
builder:
build:
context: docker/builder
hostname: builder
stdin_open: true
tty: true
privileged: true
volumes:
- .:/opt/copr:z
frontend:
build:
context: docker/frontend/
hostname: frontend
depends_on:
- database
- redis
links:
- database
stdin_open: true
tty: true
ports:
- "5000:5000"
volumes:
- .:/opt/copr:z
database:
build:
context: docker/database/
hostname: database
stdin_open: true
tty: true
environment:
- POSTGRESQL_USER=copr-fe
- POSTGRESQL_PASSWORD=coprpass
- POSTGRESQL_DATABASE=coprdb
ports:
- 5009:5432
volumes:
- database:/var/lib/pgsql/data
distgit:
build:
context: docker/distgit/
hostname: distgit
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- dist-git:/var/lib/dist-git:z
distgit-httpd:
build:
context: docker/distgit/
hostname: distgit-httpd
stdin_open: true
tty: true
ports:
- "5001:5001"
volumes:
- .:/opt/copr:z
- dist-git:/var/lib/dist-git:z
command: /usr/sbin/httpd -DFOREGROUND
keygen-signd:
build:
context: docker/keygen/
hostname: keygen-signd
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- copr-keygen:/var/lib/copr-keygen:z
command: /signd-entrypoint
keygen-httpd:
build:
context: docker/keygen/
hostname: keygen-httpd
stdin_open: true
tty: true
volumes:
- .:/opt/copr:z
- copr-keygen:/var/lib/copr-keygen:z
volumes:
results:
copr-keygen:
dist-git:
database:
redis: