]> cat aescling's git repositories - mastodon.git/blob - docker-compose.yml
docker-compose: Only bind ports 3000 and 4000 on localhost. (#7138)
[mastodon.git] / docker-compose.yml
1 version: '3'
2 services:
3
4 db:
5 restart: always
6 image: postgres:9.6-alpine
7 networks:
8 - internal_network
9 ### Uncomment to enable DB persistance
10 # volumes:
11 # - ./postgres:/var/lib/postgresql/data
12
13 redis:
14 restart: always
15 image: redis:4.0-alpine
16 networks:
17 - internal_network
18 ### Uncomment to enable REDIS persistance
19 # volumes:
20 # - ./redis:/data
21
22 # es:
23 # restart: always
24 # image: docker.elastic.co/elasticsearch/elasticsearch-oss:6.1.3
25 # environment:
26 # - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
27 # networks:
28 # - internal_network
29 #### Uncomment to enable ES persistance
30 ## volumes:
31 ## - ./elasticsearch:/usr/share/elasticsearch/data
32
33 web:
34 build: .
35 image: tootsuite/mastodon
36 restart: always
37 env_file: .env.production
38 command: bundle exec rails s -p 3000 -b '0.0.0.0'
39 networks:
40 - external_network
41 - internal_network
42 ports:
43 - "127.0.0.1:3000:3000"
44 depends_on:
45 - db
46 - redis
47 # - es
48 volumes:
49 - ./public/assets:/mastodon/public/assets
50 - ./public/packs:/mastodon/public/packs
51 - ./public/system:/mastodon/public/system
52
53 streaming:
54 build: .
55 image: tootsuite/mastodon
56 restart: always
57 env_file: .env.production
58 command: yarn start
59 networks:
60 - external_network
61 - internal_network
62 ports:
63 - "127.0.0.1:4000:4000"
64 depends_on:
65 - db
66 - redis
67
68 sidekiq:
69 build: .
70 image: tootsuite/mastodon
71 restart: always
72 env_file: .env.production
73 command: bundle exec sidekiq -q default -q mailers -q pull -q push
74 depends_on:
75 - db
76 - redis
77 networks:
78 - external_network
79 - internal_network
80 volumes:
81 - ./public/packs:/mastodon/public/packs
82 - ./public/system:/mastodon/public/system
83
84 networks:
85 external_network:
86 internal_network:
87 internal: true
This page took 0.062769 seconds and 4 git commands to generate.