-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.yml
87 lines (82 loc) · 1.66 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
version: "3.2"
services:
app:
image: mwendakith/lab:1.6
#build:
# context: ./
# dockerfile: Dockerfile
volumes:
- type: volume
source: myapp
target: /var/www/lab
working_dir: /var/www/lab
deploy:
restart_policy:
condition: on-failure
#placement:
# constraints: [node.role == worker]
networks:
- webnet
web:
image: mwendakith/nginx:latest
#build:
# context: ./
# dockerfile: web.dockerfile
volumes:
- type: volume
source: myapp
target: /var/www/lab
#working_dir: /var/www/lab
deploy:
restart_policy:
condition: on-failure
#placement:
# constraints: [node.role == worker]
ports:
- 8080:80
networks:
- webnet
smtp:
image: namshi/smtp:latest
ports:
- "25:25"
deploy:
restart_policy:
condition: on-failure
#placement:
# constraints: [node.role == worker]
environment:
MAILNAME:
networks:
- webnet
visualizer:
image: dockersamples/visualizer:stable
ports:
- "4000:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"
deploy:
restart_policy:
condition: on-failure
placement:
constraints: [node.role == manager]
networks:
- webnet
redis:
image: redis
ports:
- "10000:6379"
volumes:
- "redis_data:/data"
deploy:
placement:
constraints: [node.role == manager]
command: redis-server --appendonly yes
networks:
- webnet
networks:
webnet:
volumes:
myapp:
# driver: vsphere:latest
redis_data: