-
Notifications
You must be signed in to change notification settings - Fork 20
/
docker-compose.yml
74 lines (67 loc) · 1.55 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
version: '3.8'
services:
zookeeper:
image: wurstmeister/zookeeper
volumes:
- ./.tmp/zookeeper-data:/data
ports:
- 2182:2181
kafka9094:
image: wurstmeister/kafka
ports:
- 9092:9092
environment:
KAFKA_BROKER_ID: 0
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://192.168.1.60:9092
KAFKA_CREATE_TOPICS: "kafeidou:2:0" #kafka启动后初始化一个有2个partition(分区)0个副本名叫kafeidou的topic
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_LISTENERS: PLAINTEXT://0.0.0.0:9092
volumes:
- ./.tmp/kafka-logs:/kafka
depends_on:
- zookeeper
db:
build: ./pgsql
restart: unless-stopped
volumes:
# - ./pgsql/postgresqltuner_init.sh:/docker-entrypoint-initdb.d/00_postgresqltuner_init.sh
- ./pgsql/init_db.sh:/docker-entrypoint-initdb.d/10_init_db.sh
environment:
- POSTGRES_PASSWORD=123
- POSTGRES_USER=postgres
- POSTGRES_DB=findy
financenter:
build: ./
restart: unless-stopped
volumes:
- $PWD/:/work
depends_on:
- kafka9094
- db
app:
container_name: app
restart: always
env_file: .env
build: .
networks:
- db_network
- web_network
depends_on:
- financenter
nginx:
container_name: nginx5085
restart: always
image: "nginx:latest"
ports:
- "5085:5085"
volumes:
- ./nginx:/etc/nginx/conf.d
networks:
- web_network
depends_on:
- app
networks:
db_network:
driver: bridge
web_network:
driver: bridge