-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.test.yml
More file actions
42 lines (40 loc) · 858 Bytes
/
docker-compose.test.yml
File metadata and controls
42 lines (40 loc) · 858 Bytes
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
services:
gateway:
image: nginx:latest
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
- ./nginx/htpasswd:/etc/nginx/.htpasswd
- ./web:/usr/share/nginx/html
ports:
- "8197:8197"
depends_on:
- service1
- service2
networks:
- app-network
service1:
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /dev/shm:/shared-data
# Define which docker file to use
build: ./service1
# Map inside port to outside port
expose:
- "8199"
# Ensure Service2 is started before Service1
depends_on:
- service2
networks:
- app-network
deploy:
replicas: 3
service2:
# Define which docker file to use
build: ./service2
expose:
- "8080"
networks:
- app-network
networks:
app-network:
driver: bridge