forked from jhongwei80/tesla
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
59 lines (59 loc) · 1.72 KB
/
docker-compose.yaml
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
version: '3.1'
services:
tesla-mysql:
container_name: tesla-mysql
image: mysql:5.7
ports:
- "3306:3306"
command: --character-set-server=utf8 --collation-server=utf8_general_ci
volumes:
- ./sql:/docker-entrypoint-initdb.d
environment:
MYSQL_ROOT_PASSWORD: 123456
MYSQL_DATABASE: gateway
MYSQL_USER: user
MYSQL_PASSWORD: 123456
LANG: C.UTF-8
restart: always
tesla-backend-sample:
container_name: tesla-backend-sample
image: tesla-backend-sample:1.0.0
ports:
- 8902:8902
- 2181:2181
environment:
- EUREKA_SERVER=http://eureka.springcloud.cn/eureka/
restart: always
tesla-ops:
container_name: tesla-ops
image: tesla-ops:1.0.0
command: ["dockerize", "-wait", "tcp://tesla-mysql:3306", "-timeout", "1800s","./start.sh"]
ports:
- 8080:8080
environment:
- DATABASE_HOST=tesla-mysql
- DATABASE_USER=root
- DATABASE_PASSWORD=123456
- DATABASE_NAME=gateway
- DATABASE_PORT=3306
- EUREKA_SERVER=http://eureka.springcloud.cn/eureka/
restart: always
tesla-gateway:
container_name: tesla-gateway
image: tesla-gateway:1.0.0
command: ["dockerize", "-wait", "tcp://tesla-mysql:3306", "-wait", "tcp://tesla-backend-sample:2181", "-timeout", "1800s","./start.sh"]
depends_on:
- tesla-mysql
- tesla-backend-sample
ports:
- 9000:9000
- 5701:5701
environment:
- DATABASE_HOST=tesla-mysql
- DATABASE_USER=root
- DATABASE_PASSWORD=123456
- DATABASE_NAME=gateway
- DATABASE_PORT=3306
- EUREKA_SERVER=http://eureka.springcloud.cn/eureka/
- ZOOKEEPER_SERVER=zookeeper://tesla-backend-sample:2181
restart: always