This repository has been archived by the owner on Sep 14, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yml
95 lines (76 loc) · 1.75 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
88
89
90
91
92
93
94
95
version: '3.7'
services:
backend:
container_name: backend
build:
context: .
dockerfile: dockerfiles/backend.Dockerfile
volumes:
- ./researchhub-backend:/researchhub-backend
hostname: dev-backend.researchhub.com
command: bash -c "python3 manage.py makemigrations && python3 manage.py migrate && python3 manage.py runserver 0.0.0.0:8000"
expose:
- 8000
env_file:
- .env.dev
depends_on:
- db
web:
image: node
build:
context: .
dockerfile: dockerfiles/frontend.Dockerfile
restart: unless-stopped
volumes:
- ./researchhub-web:/researchhub-web
hostname: dev.researchhub.com
expose:
- 3000
db:
image: postgres:12
volumes:
- postgres_data:/var/lib/postgresql/data/
env_file:
- .env.dev
nginx:
image: nginx:latest
container_name: nginx
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf
- ./ssl:/etc/ssl/
ports:
- 80:80
- 443:443
depends_on:
- web
- backend
redis:
image: docker.io/bitnami/redis
environment:
# ALLOW_EMPTY_PASSWORD is recommended only for development.
- ALLOW_EMPTY_PASSWORD=yes
- REDIS_DISABLE_COMMANDS=FLUSHDB,FLUSHALL
expose:
- 6379
volumes:
- 'redis_data:/bitnami/redis/data'
elastic-search:
image: docker.elastic.co/elasticsearch/elasticsearch:7.10.2
ports:
- 9200:9200
- 9300:9300
restart: unless-stopped
networks:
- researchhub-network
environment:
- discovery.type=single-node
- node.name=researchhub-elasticsearch
depends_on:
- redis
volumes:
postgres_data:
redis_data:
driver: local
networks:
researchhub-network:
driver: bridge