-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
118 lines (107 loc) · 2.53 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
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
version: "2"
services:
uwsgi:
build: .
command: >
sh -cex "
cd /last_fm;
exec /virtualenv/bin/uwsgi --master --module last_fm:app --processes 5 --enable-threads --chmod-socket=666 --socket /var/run/last_fm/uwsgi.socket;
"
env_file: .env
links:
- postgres
- rabbitmq
- redis
- sync_scrobbles_daemon
external_links:
- twitteroverkill_api_1:twitter-overkill
networks:
- default
- twitteroverkill_default
restart: always
volumes:
- "$STATIC_DATA_PATH/artists:/last_fm/last_fm/static/artists"
- "$STATIC_DATA_PATH/covers:/last_fm/last_fm/static/covers"
- /run/mpd/socket:/run/mpd/socket
- run:/var/run/last_fm
gunicorn:
build: .
command: /virtualenv/bin/gunicorn --bind unix:/var/run/last_fm/gunicorn.socket --worker-class "geventwebsocket.gunicorn.workers.GeventWebSocketWorker" last_fm:api.app
env_file: .env
links:
- postgres
- rabbitmq
- redis
restart: always
volumes_from:
- uwsgi
worker:
build: .
command: /virtualenv/bin/celery worker -A last_fm:celery -l INFO
env_file: .env
environment:
C_FORCE_ROOT: "yes"
links:
- postgres
- rabbitmq
- redis
- sync_scrobbles_daemon
external_links:
- twitteroverkill_api_1:twitter-overkill
networks:
- default
- twitteroverkill_default
restart: always
volumes_from:
- uwsgi
scheduler:
build: .
command: /virtualenv/bin/celery beat -A last_fm:celery -s /var/lib/scheduler/schedule --pidfile=
env_file: .env
links:
- rabbitmq
restart: always
volumes:
- scheduler-data:/var/lib/scheduler
volumes_from:
- uwsgi
sync_scrobbles_daemon:
build: .
command: /virtualenv/bin/python -m last_fm.sync_scrobbles_daemon
env_file: .env
links:
- postgres
- redis
restart: always
nginx:
build: nginx
ports:
- "$PORT:80"
restart: always
volumes_from:
- uwsgi
postgres:
image: postgres:latest
environment:
LC_ALL: C.UTF-8
POSTGRES_DB: last_fm
POSTGRES_USER: last_fm
POSTGRES_PASSWORD: last_fm
volumes:
- "$POSTGRES_DATA_PATH:/var/lib/postgresql/data"
rabbitmq:
image: rabbitmq:latest
volumes:
- rabbitmq-data:/var/lib/rabbitmq
redis:
image: redis:latest
volumes:
- redis-data:/data
networks:
twitteroverkill_default:
external: true
volumes:
rabbitmq-data:
redis-data:
run:
scheduler-data: