This repository has been archived by the owner on Aug 7, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 44
/
docker-compose.yml
96 lines (84 loc) · 2.68 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
96
# EXAMPLE AT: https://github.com/nevercaution/docker-django-uwsgi-nginx
version: "3.4"
volumes:
volume_radar_pg_data:
volume_radar_django_static:
volume_radar_sockets:
volume_radar_elasticsearch_data:
services:
rabbitmq:
image: rabbitmq:3.7-alpine
memcache:
image: memcached:1.5-alpine
elasticsearch:
image: elasticsearch:2.4-alpine # docker.elastic.co/elasticsearch/elasticsearch:6.2.3
# Estamos usando uma versão velha do ElasticSearch para não ter que
# dar o seguinte comando no host:
# sysctl -w vm.max_map_count=262144
# https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html
volumes:
- ./deploy/elasticsearch/hunspell:/usr/share/elasticsearch/config/hunspell
- volume_radar_elasticsearch_data:/usr/share/elasticsearch/data
postgres:
image: postgres:10.4-alpine
environment:
- POSTGRES_USER=radar
- POSTGRES_PASSWORD=${RADAR_DB_PASSWORD:-radar}
- POSTGRES_DB=radar
- PGDATA=/var/lib/postgresql/data/pgdata
volumes:
- volume_radar_pg_data:/var/lib/postgresql/data/pgdata
nginx:
image: nginx:1.13-alpine
volumes:
- volume_radar_django_static:/radar/radar_parlamentar/static
- volume_radar_sockets:/radar/sockets/
- ./deploy:/radar/deploy
- ./deploy/radar.nginx.conf:/etc/nginx/conf.d/default.conf
ports:
- "80:80"
- "443:443"
django:
image: radarparlamentar/radar
build: .
environment:
- RADAR_DB_PASSWORD=${RADAR_DB_PASSWORD:-radar}
- RADAR_IS_PRODUCTION=${RADAR_IS_PRODUCTION}
volumes:
- .:/radar
- volume_radar_sockets:/radar/sockets/
- volume_radar_django_static:/radar/radar_parlamentar/static
links:
- postgres
- memcache
- rabbitmq
- elasticsearch
- nginx # because CashRefresherJob
depends_on:
- postgres
- nginx
- memcache
- rabbitmq
- celery
- elasticsearch
celery:
image: radarparlamentar/radar
environment:
- RADAR_DB_PASSWORD=${RADAR_DB_PASSWORD:-radar}
volumes:
- .:/radar
links:
- postgres
- rabbitmq
depends_on:
- postgres
- rabbitmq
command:
- celery
test:
build: .
image: radarparlamentar/test
volumes:
- .:/radar
command:
- test