-
Notifications
You must be signed in to change notification settings - Fork 65
/
docker-compose.yml
75 lines (71 loc) · 1.69 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
version: '3'
services:
nestjs-example:
build:
context: .
args:
- env=development
ports:
- '8080:80'
environment:
DB_HOST: nestjs-example-db
DB_PORT: 5432
DB_USERNAME: postgres
DB_PASSWORD: postgres
REDIS_HOST: nestjs-example-redis
REDIS_PORT: 6379
RABBITMQ_HOST: nestjs-example-rabbitmq
RABBITMQ_PORT: 5672
RABBITMQ_USERNAME: admin
RABBITMQ_PASSWORD: password
# volumes:
# - ./appdata:/server/uploads
links:
- nestjs-example-db
- nestjs-example-redis
- nestjs-example-rabbitmq
depends_on:
- nestjs-example-db
- nestjs-example-redis
- nestjs-example-rabbitmq
networks:
- nestjs-example-network
container_name: nestjs-example
restart: on-failure
nestjs-example-db:
image: postgres:13-alpine
environment:
POSTGRES_PASSWORD: postgres
expose:
- "5432"
# volumes:
# - ./pgdata:/var/lib/postgresql/data
networks:
- nestjs-example-network
container_name: nestjs-example-db
restart: on-failure
nestjs-example-redis:
image: redis:7-alpine
expose:
- "6379"
# volumes:
# - ./redisdata:/var/lib/redis
networks:
- nestjs-example-network
container_name: nestjs-example-redis
restart: on-failure
nestjs-example-rabbitmq:
image: rabbitmq:4.0.3-alpine
environment:
RABBITMQ_DEFAULT_USER: admin
RABBITMQ_DEFAULT_PASS: password
RABBITMQ_DEFAULT_VHOST: vhost
expose:
- "5672"
networks:
- nestjs-example-network
container_name: nestjs-example-rabbitmq
restart: on-failure
networks:
nestjs-example-network:
external: true