-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
88 lines (84 loc) · 2.04 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
version: '3'
services:
kong-database:
image: postgres:9.6
restart: always
networks:
- kong-net
environment:
- "POSTGRES_USER=kong"
- "POSTGRES_DB=kong"
- "POSTGRES_PASSWORD=kong"
volumes:
- ./data/kong_database:/var/lib/postgresql/data
ports:
- "5432:5432"
kong-migration:
image: kong:latest
command: "kong migrations bootstrap -v"
restart: on-failure
networks:
- kong-net
environment:
- "KONG_DATABASE=postgres"
- "KONG_PG_DATABASE=kong"
- "KONG_PG_PASSWORD=kong"
- "KONG_PG_HOST=kong-database"
- "KONG_CASSANDRA_CONTACT_POINTS=kong-database"
depends_on:
- kong-database
#####################
# kong gateway
#####################
kong:
image: kong:latest
restart: always
networks:
- kong-net
environment:
- "KONG_DATABASE=postgres"
- "KONG_PG_HOST=kong-database"
- "KONG_PG_USER=kong"
- "KONG_PG_PASSWORD=kong"
- "KONG_CASSANDRA_CONTACT_POINTS=kong-database"
- "KONG_PROXY_ACCESS_LOG=/dev/stdout"
- "KONG_ADMIN_ACCESS_LOG=/dev/stdout"
- "KONG_PROXY_ERROR_LOG=/dev/stderr"
- "KONG_ADMIN_ERROR_LOG=/dev/stderr"
- "KONG_ADMIN_LISTEN=0.0.0.0:8001, 0.0.0.0:8444 ssl"
- "KONG_PROXY_LISTEN=0.0.0.0:8000"
- "KONG_ADMIN_GUI_URL=http://localhost:8002"
depends_on:
- kong-database
healthcheck:
test: ["CMD", "curl", "-f", "http://kong:8001"]
interval: 5s
timeout: 2s
retries: 15
ports:
- "8002:8002"
- "8001:8001"
- "8000:8000"
- "8444:8444"
konga:
image: pantsel/konga
restart: always
networks:
- kong-net
environment:
- "TOKEN_SECRET=51liveup.cn"
- "NODE_ENV=development"
- "DB_ADAPTER=postgres"
- "DB_HOST=kong-database"
- "DB_PORT=5432"
- "DB_USER=kong"
- "DB_PASSWORD=kong"
- "DB_DATABASE=konga"
depends_on:
- kong
- kong-database
ports:
- "1337:1337"
networks:
kong-net:
external: true