Created
April 15, 2017 16:44
-
-
Save tateisu/646969c6281c9ef99c24a765cbd701ef to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2' | |
services: | |
db: | |
restart: always | |
image: postgres:alpine | |
### Uncomment to enable DB persistance | |
volumes: | |
- /mnt/hdd/mastodon/postgres:/var/lib/postgresql/data | |
redis: | |
restart: always | |
image: redis:alpine | |
### Uncomment to enable REDIS persistance | |
volumes: | |
- /mnt/hdd/mastodon/redis:/data | |
web: | |
restart: always | |
build: . | |
env_file: .env.production | |
command: bundle exec rails s -p 3000 -b '0.0.0.0' | |
ports: | |
- "172.17.0.1:3000:3000" | |
depends_on: | |
- db | |
- redis | |
volumes: | |
- /mnt/hdd/mastodon/public/assets:/mastodon/public/assets | |
- /mnt/hdd/mastodon/public/system:/mastodon/public/system | |
streaming: | |
restart: always | |
build: . | |
env_file: .env.production | |
command: npm run start | |
ports: | |
- "172.17.0.1:4000:4000" | |
depends_on: | |
- db | |
- redis | |
sidekiq1: | |
restart: always | |
build: . | |
env_file: .env.production | |
command: bundle exec sidekiq -c 10 -q default | |
depends_on: | |
- db | |
- redis | |
volumes: | |
- /mnt/hdd/mastodon/public/system:/mastodon/public/system | |
sidekiq2: | |
restart: always | |
build: . | |
env_file: .env.production | |
command: bundle exec sidekiq -c 10 -q mailers | |
depends_on: | |
- db | |
- redis | |
volumes: | |
- /mnt/hdd/mastodon/public/system:/mastodon/public/system | |
sidekiq3: | |
restart: always | |
build: . | |
env_file: .env.production | |
command: bundle exec sidekiq -c 10 -q pull | |
depends_on: | |
- db | |
- redis | |
volumes: | |
- /mnt/hdd/mastodon/public/system:/mastodon/public/system | |
sidekiq4: | |
restart: always | |
build: . | |
command: bundle exec sidekiq -c 20 -q push | |
env_file: .env.production | |
depends_on: | |
- db | |
- redis | |
volumes: | |
- /mnt/hdd/mastodon/public/system:/mastodon/public/system |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment