-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathdocker-compose.yml
88 lines (86 loc) · 2.37 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:
api:
container_name: node_kong_api
build: "."
ports:
- "8004:8004"
networks:
- kong-net
kong-database:
container_name: kong-database
image: 'postgres:9.6'
working_dir: /usr/app
volumes:
- ${PWD}/postgres/data:/var/lib/postgresql/data
restart: always
environment:
POSTGRES_USER: user
POSTGRES_PASSWORD: 12345
POSTGRES_DB : kong_db
ports:
- "5432:5432"
healthcheck:
test: ["CMD", "pg_isready", "-U", "user"]
interval: 5s
timeout: 5s
retries: 5
networks:
- kong-net
kong:
container_name: kong
image: kong:latest
restart: always
environment:
KONG_LOG_LEVEL: debug
KONG_DATABASE: postgres
KONG_PG_HOST: kong-database
KONG_PG_DATABASE: kong_db
KONG_PG_USER: user
KONG_PG_PASSWORD: 12345
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
KONG_PROXY_LISTEN: 0.0.0.0:8000
KONG_PROXY_LISTEN_SSL: 0.0.0.0:8443
depends_on:
- kong-database
- api
healthcheck:
test: ["CMD", "kong", "health"]
interval: 10s
timeout: 10s
retries: 10
ports:
- "8000:8000/tcp"
- "8001:8001/tcp"
- "8443:8443/tcp"
- "8444:8444/tcp"
networks:
- kong-net
konga:
container_name: konga
image: pantsel/konga:next
restart: always
environment:
DB_ADAPTER: postgres
DB_HOST: kong-database
DB_USER: user
DB_PASSWORD: 12345
TOKEN_SECRET: km1GUr4RkcQD7DewhJPNXrCuZwcKmqjb
DB_DATABASE: konga_db
NODE_ENV: production
networks:
- kong-net
depends_on:
- kong-database
- kong
ports:
- "1337:1337"
networks:
kong-net:
driver: bridge
# docker exec -it product_db bash
# psql postgres -U user -p 5432 product_db