-
Notifications
You must be signed in to change notification settings - Fork 56
/
docker-compose.yml
170 lines (163 loc) · 4.43 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
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
networks:
pongo-test-network:
name: ${SERVICE_NETWORK_NAME}
services:
expose:
image: pongo-expose
build: ./expose
ports:
- "8000:8000"
- "8001:8001"
- "8002:8002"
- "8003:8003"
- "8004:8004"
- "8443:8443"
- "8444:8444"
- "8445:8445"
# Postgres
- "5432:5432"
# Cassandra
- "7000:7000"
- "7001:7001"
- "7199:7199"
- "9042:9042"
- "9160:9160"
# Redis
- "6379:6379"
- "6380:6380"
environment:
EXPOSE: "kong:8000 kong:8001 kong:8002 kong:8003 kong:8004 kong:8443 kong:8444 kong:8445 postgres:5432 cassandra:7000 cassandra:7001 cassandra:7199 cassandra:9042 cassandra:9160 redis:6379 redis:6380"
healthcheck:
interval: 5s
retries: 10
test:
- CMD
- test
- -e
- /ready
timeout: 10s
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
- pongo-test-network
postgres:
image: ${POSTGRES_IMAGE:-postgres:9.5}
environment:
POSTGRES_USER: kong
POSTGRES_DB: kong_tests
POSTGRES_HOST_AUTH_METHOD: trust
healthcheck:
interval: 5s
retries: 10
test:
- CMD
- pg_isready
- --dbname=kong_tests
- --username=kong
timeout: 10s
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-postgres.${SERVICE_NETWORK_NAME}
cassandra:
image: ${CASSANDRA_IMAGE:-cassandra:3.11}
environment:
MAX_HEAP_SIZE: 256M
HEAP_NEWSIZE: 128M
healthcheck:
test: ["CMD", "cqlsh", "-e", "describe keyspaces"]
interval: 5s
timeout: 10s
retries: 10
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-cassandra.${SERVICE_NETWORK_NAME}
redis:
image: ${REDIS_IMAGE:-redis:6.2.6-alpine}
volumes:
- "./redis/server.crt:/usr/local/etc/redis/server.crt"
- "./redis/server.key:/usr/local/etc/redis/server.key"
command: >-
--tls-port 6380
--tls-cert-file /usr/local/etc/redis/server.crt
--tls-key-file /usr/local/etc/redis/server.key
--tls-cluster no
--tls-replication no
--tls-auth-clients no
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 10s
retries: 10
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-redis.${SERVICE_NETWORK_NAME}
squid:
image: ${SQUID_IMAGE:-sameersbn/squid:3.5.27-2}
volumes:
- ./squid/squid.conf:/etc/squid/squid.conf
- ./squid/passwords:/etc/squid/passwords
healthcheck:
interval: 5s
retries: 10
test: ["CMD", "kill", "-0", "1"]
timeout: 10s
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-squid.${SERVICE_NETWORK_NAME}
grpcbin:
image: ${GRPCBIN_IMAGE:-moul/grpcbin:latest}
healthcheck:
interval: 5s
retries: 10
test: ["CMD", "kill", "-0", "1"]
timeout: 10s
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
restart: on-failure
stop_signal: SIGKILL
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-grpcbin.${SERVICE_NETWORK_NAME}
kong:
image: ${KONG_TEST_IMAGE:-ignore_if_not_provided}
environment:
- KONG_CASSANDRA_CONTACT_POINTS=${SERVICE_NETWORK_NAME}-cassandra.${SERVICE_NETWORK_NAME}
- KONG_PG_HOST=${SERVICE_NETWORK_NAME}-postgres.${SERVICE_NETWORK_NAME}
- PONGO_COMMAND=${ACTION}
- PONGO_NETWORK=${SERVICE_NETWORK_NAME}
- PONGO_ID=${PROJECT_ID}
healthcheck:
interval: 5s
retries: 10
test:
- CMD
- kong
- health
- --prefix=/kong-plugin/servroot/
timeout: 10s
disable: ${SERVICE_DISABLE_HEALTHCHECK:-false}
extra_hosts:
- "host.docker.internal:host-gateway"
networks:
pongo-test-network:
aliases:
- ${SERVICE_NETWORK_NAME}-kong.${SERVICE_NETWORK_NAME}
volumes:
- ${PONGO_WD}:/kong-plugin