Jafner.net/docker_config/peertube/docker-compose.yml

69 lines
1.8 KiB
YAML
Raw Normal View History

2021-03-01 11:45:53 -08:00
version: "3"
2021-07-05 13:33:34 -07:00
2021-03-01 11:45:53 -08:00
services:
peertube:
2021-07-05 13:33:34 -07:00
# If you don't want to use the official image and build one from sources:
# build:
# context: .
# dockerfile: ./support/docker/production/Dockerfile.buster
image: chocobozzz/peertube:production-buster
# Use a static IP for this container because nginx does not handle proxy host change without reload
# This container could be restarted on crash or until the postgresql database is ready for connection
2021-03-01 11:45:53 -08:00
networks:
2021-07-05 13:33:34 -07:00
default:
ipv4_address: 172.18.0.42
web:
2021-03-01 11:45:53 -08:00
env_file:
- .env
2021-07-05 13:33:34 -07:00
ports:
- "1935:1935" # If you don't want to use the live feature, you can comment this line
# - "9000:9000" # If you provide your own webserver and reverse-proxy, otherwise not suitable for production
labels:
2021-03-01 11:45:53 -08:00
- traefik.http.routers.peertube.rule=Host(`peertube.jafner.net`)
- traefik.http.routers.peertube.tls=true
- traefik.http.routers.peertube.tls.certresolver=lets-encrypt
- traefik.http.services.peertube.loadbalancer.server.port=9000
volumes:
2021-07-05 13:33:34 -07:00
- assets:/app/client/dist
- ${DOCKER_DATA}/data:/data
- ${DOCKER_DATA}/config:/config
2021-03-01 11:45:53 -08:00
depends_on:
- postgres
- redis
- postfix
restart: "always"
postgres:
2021-07-05 13:33:34 -07:00
image: postgres:13-alpine
env_file:
- .env
2021-03-01 11:45:53 -08:00
volumes:
2021-07-05 13:33:34 -07:00
- ${DOCKER_DATA}/db:/var/lib/postgresql/data
2021-03-01 11:45:53 -08:00
restart: "always"
redis:
2021-07-05 13:33:34 -07:00
image: redis:6-alpine
2021-03-01 11:45:53 -08:00
volumes:
2021-07-05 13:33:34 -07:00
- ${DOCKER_DATA}/redis:/data
2021-03-01 11:45:53 -08:00
restart: "always"
2021-07-05 13:33:34 -07:00
2021-03-01 11:45:53 -08:00
postfix:
image: mwader/postfix-relay
2021-07-05 13:33:34 -07:00
env_file:
- .env
volumes:
- ${DOCKER_DATA}/opendkim/keys:/etc/opendkim/keys
2021-03-01 11:45:53 -08:00
restart: "always"
networks:
default:
ipam:
driver: default
config:
2021-07-05 13:33:34 -07:00
- subnet: 172.18.0.0/16
2021-03-01 11:45:53 -08:00
web:
external: true
2021-07-05 13:33:34 -07:00
volumes:
assets: