2024-10-20 21:45:05 +02:00
|
|
|
networks:
|
|
|
|
mastodon:
|
|
|
|
external: false
|
|
|
|
enable_ipv6: true
|
|
|
|
|
|
|
|
services:
|
|
|
|
redis:
|
|
|
|
image: redis:7-alpine
|
|
|
|
restart: always
|
|
|
|
healthcheck:
|
|
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
|
|
networks:
|
|
|
|
- mastodon
|
|
|
|
|
|
|
|
web:
|
2024-12-03 17:05:24 +01:00
|
|
|
image: ghcr.io/mastodon/mastodon:v4.3.2
|
2024-10-20 21:45:05 +02:00
|
|
|
restart: always
|
2024-10-20 21:47:06 +02:00
|
|
|
env_file:
|
|
|
|
- path: .env.production
|
|
|
|
- path: .env
|
|
|
|
required: false
|
2024-10-20 21:45:05 +02:00
|
|
|
command: bundle exec puma -C config/puma.rb
|
|
|
|
healthcheck:
|
|
|
|
# prettier-ignore
|
|
|
|
test: ['CMD-SHELL', 'wget -q --spider --proxy=off localhost:3000/health || exit 1']
|
|
|
|
networks:
|
|
|
|
- mastodon
|
|
|
|
ports:
|
|
|
|
- "4004:3000"
|
|
|
|
depends_on:
|
|
|
|
- redis
|
|
|
|
labels:
|
|
|
|
- "traefik.enable=true"
|
|
|
|
- "traefik.http.routers.mastodon-web.entrypoints=websecure"
|
|
|
|
- "traefik.http.routers.mastodon-web.rule=Host(`toot.gnous.eu`)"
|
|
|
|
- "traefik.http.routers.mastodon-web.tls=true"
|
|
|
|
- "traefik.http.routers.mastodon-web.tls.certresolver=defaultacme"
|
|
|
|
- "traefik.http.routers.mastodon-web.middlewares=proxyHeader@file,proxyError@file"
|
|
|
|
# Cron
|
|
|
|
- "ofelia.enabled=true"
|
|
|
|
- "ofelia.job-exec.clean-media.schedule=@daily"
|
|
|
|
- "ofelia.job-exec.clean-media.command=tootctl media remove --days 7"
|
|
|
|
- "ofelia.job-exec.clean-account.schedule=@monthly"
|
|
|
|
- "ofelia.job-exec.clean-account.command=tootctl accounts cull"
|
|
|
|
|
|
|
|
streaming:
|
2024-12-03 16:33:47 +01:00
|
|
|
image: ghcr.io/mastodon/mastodon-streaming:v4.3.2
|
2024-10-20 21:45:05 +02:00
|
|
|
restart: always
|
2024-10-20 21:47:06 +02:00
|
|
|
env_file:
|
|
|
|
- path: .env.production
|
|
|
|
- path: .env
|
|
|
|
required: false
|
2024-10-20 21:45:05 +02:00
|
|
|
command: node ./streaming/index.js
|
|
|
|
healthcheck:
|
|
|
|
# prettier-ignore
|
|
|
|
test: ['CMD-SHELL', "curl -s --noproxy localhost localhost:4000/api/v1/streaming/health | grep -q 'OK' || exit 1"]
|
|
|
|
ports:
|
|
|
|
- "127.0.0.1:4000:4000"
|
|
|
|
depends_on:
|
|
|
|
- redis
|
|
|
|
networks:
|
|
|
|
- mastodon
|
|
|
|
labels:
|
|
|
|
- "traefik.enable=true"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.entrypoints=websecure"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.rule=(Host(`toot.gnous.eu`) && PathPrefix(`/api/v1/streaming`))"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.tls.certresolver=letsencrypt"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.tls=true"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.tls.certresolver=defaultacme"
|
|
|
|
- "traefik.http.routers.mastodon-streaming.middlewares=proxyHeader@file,proxyError@file"
|
|
|
|
|
|
|
|
sidekiq:
|
2024-12-03 17:05:24 +01:00
|
|
|
image: ghcr.io/mastodon/mastodon:v4.3.2
|
2024-10-20 21:45:05 +02:00
|
|
|
restart: always
|
2024-10-20 21:47:06 +02:00
|
|
|
env_file:
|
|
|
|
- path: .env.production
|
|
|
|
- path: .env
|
|
|
|
required: false
|
2024-10-20 21:45:05 +02:00
|
|
|
command: bundle exec sidekiq
|
|
|
|
healthcheck:
|
|
|
|
test: ["CMD-SHELL", "ps aux | grep '[s]idekiq\ 6' || false"]
|
|
|
|
networks:
|
|
|
|
- mastodon
|
|
|
|
depends_on:
|
|
|
|
- redis
|