forked from docker-flow/docker-flow-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-test.yml
103 lines (91 loc) · 2.37 KB
/
docker-compose-test.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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
version: '2'
services:
unit:
image: golang:1.6
volumes:
- .:/usr/src/myapp
- /tmp/go:/go
working_dir: /usr/src/myapp
command: sh -c "go get -d -v -t && go test --cover ./... --run UnitTest && go build -v -o docker-flow-proxy"
staging-dep:
image: ${DOCKER_HUB_USER}/docker-flow-proxy
environment:
- CONSUL_ADDRESS=consul:8500
- PROXY_INSTANCE_NAME=proxy-test-instance
- USERS=user1:pass1,user2:pass2
- STATS_USER=stats
- STATS_PASS=pass
ports:
- 80:80
- 443:443
- 8080:8080
volumes:
- ./test_configs/:/test_configs/
depends_on:
- staging-service-proxy
- consul
- registrator
- app-1
staging-service-proxy:
image: ${DOCKER_HUB_USER}/docker-flow-proxy
environment:
- PROXY_INSTANCE_NAME=proxy-service-test-instance
- MODE=swarm
ports:
- 9000:80
- 9080:8080
volumes:
- ./test_configs/:/test_configs/
staging:
image: vfarcic/docker-flow-proxy-test
volumes:
- .:/usr/src/myapp
- /tmp/go:/go
- /var/run/docker.sock:/var/run/docker.sock
environment:
- DOCKER_IP=${HOST_IP}
- CONSUL_IP=${HOST_IP}
working_dir: /usr/src/myapp
command: bash -c "go get -d -v -t && go test --run IntegrationTest ./..."
staging-swarm:
image: vfarcic/docker-flow-proxy-test
volumes:
- .:/usr/src/myapp
- /tmp/go:/go
- /var/run/docker.sock:/var/run/docker.sock
environment:
- HOST_IP=${HOST_IP}
- DOCKER_HUB_USER=${DOCKER_HUB_USER}
working_dir: /usr/src/myapp
command: bash -c "go get -d -v -t && go test -v --run IntegrationSwarmTest ./..."
production:
extends:
service: staging
consul:
image: progrium/consul
ports:
- 8500:8500
- 8301:8301
- 8300:8300
command: -server -bootstrap
registrator:
image: gliderlabs/registrator
volumes:
- /var/run/docker.sock:/tmp/docker.sock
command: -ip app-1 -internal consul://consul:8500
depends_on:
- consul
app-1:
image: vfarcic/docker-flow-proxy
environment:
CONSUL_ADDRESS: consul:8500
SERVICE_8080_NAME: test-service
ports:
- 8080
depends_on:
- consul
docs:
image: cilerler/mkdocs
volumes:
- .:/docs
command: bash -c "pip install pygments && pip install pymdown-extensions && mkdocs build"