-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
68 lines (65 loc) · 1.48 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
version: '3'
services:
service-config-push:
build: ./service-config-push
depends_on:
- consul2
environment:
RUN_DOCKER_MODE: "on"
service-discuss-room:
build: ./service-discuss-room
depends_on:
- consul2
- redis
- mysql_db
- service-config-push
environment:
RUN_DOCKER_MODE: "on"
service-web:
build: ./service-web
depends_on:
- consul2
- redis
- mysql_db
- service-config-push
environment:
RUN_DOCKER_MODE: "on"
service-auth:
build: ./service-auth
depends_on:
- redis
- service-config-push
environment:
RUN_DOCKER_MODE: "on"
service-auth-client:
build: ./service-auth-client
depends_on:
- service-auth
environment:
RUN_DOCKER_MODE: "on"
redis:
image: "redis:latest"
ports:
- "6379:6379"
mysql_db:
image: "mysql:latest"
restart: always
#command: --default-authentication-plugin=mysql_native_password
environment:
MYSQL_ROOT_PASSWORD: "123456"
volumes:
- "${HOME}/mysql/data:/var/lib/mysql"
ports:
- "3306:3306"
consul1:
image: consul
container_name: node1
command: agent -server -bootstrap-expect=1 -node=node1 -bind=0.0.0.0 -client=0.0.0.0 -datacenter=dc1
consul2:
image: consul
container_name: node2
command: agent -retry-join=node1 -node=node2 -bind=0.0.0.0 -client=0.0.0.0 -datacenter=dc1 -ui
ports:
- 8500:8500
depends_on:
- consul1