forked from trekhleb/hello-docker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
41 lines (41 loc) · 1 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
version: '3'
services:
web:
# Replace username/repo:tag with your name and image details.
image: '1010124/test-py:release-0.0.20'
networks:
- 'webapp'
# ports:
# - 80:80
#restart: always
deploy:
replicas: 3
update_config:
parallelism: 2
delay: 1s
resources:
limits:
cpus: "0.2"
memory: 100M
restart_policy:
condition: on-failure
redis:
image: redis
volumes:
- "/home/docker/data:/data"
networks:
- 'webapp'
command: redis-server --appendonly yes
# restart: always
nginx:
image: '1010124/nginx-balancer:version1'
working_dir: /app
ports:
- 80:80
volumes:
- /home/docker/data/logs/nginx:/var/log/nginx
networks:
- 'webapp'
# restart: always
networks:
webapp: