This repository was archived by the owner on Nov 18, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.yml
61 lines (55 loc) · 1.46 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
version: "3.8"
services:
db:
restart: always
build: ./postgres
container_name: arxivapp_postgres
env_file:
- postgres/database.env
expose:
- 5432
volumes:
- database:/var/lib/postgresql/data/
networks:
- arxivapp_network
web:
restart: always
build:
context: ./code
container_name: arxivapp_web
command: sh -c "python manage.py collectstatic --no-input && python manage.py makemigrations && python manage.py migrate && gunicorn ArxivAppBackend.wsgi -b 0.0.0.0:8000"
volumes:
- ./code/:/code/
- ./static/:/static/
expose:
- 8000
depends_on:
- db
networks:
- arxivapp_network
frontend:
container_name: arxivapp_frontend
build: ./frontend
volumes:
- frontend_build:/frontend/build/
networks:
- arxivapp_network
nginx:
build: ./nginx
container_name: arxivapp_nginx
ports:
- "54321:80"
volumes:
- ./static/:/static/
- ./nginx/configuration/:/etc/nginx/conf.d/
- frontend_build:/var/www/frontend/
depends_on:
- web
- frontend
networks:
- arxivapp_network
volumes:
database:
frontend_build:
networks:
arxivapp_network: