1
Fork 0
poke/docker-compose.yml

112 lines
3.6 KiB
YAML
Raw Permalink Normal View History

2024-04-22 17:38:01 -04:00
# To run this entire stack (contains all services):
# 1. Verify you have docker and docker-compose
# 2. Make sure this repository is cloned recursively (check if the `pokevidious` folder has stuff in it)
2024-04-22 17:57:50 -04:00
# 3. Proceed either to Section A or Section B
# Section A : Local development
# 1. Add this to your hosts file /etc/hosts (Linux) or C:\Windows\System32\drivers\etc\hosts (Windows)
#
# 127.0.0.1 poketube.test image-proxy.poketube.test eu-proxy.poketube.test p.poketube.test
#
# 2. Run `docker-compose up -d` or `docker compose up -d` (notice the dash)
# 3. Visit `http://poketube.test` in your browser
# Section B : Production
# 3. Adjust domains in `docker/Caddyfile` and `docker/config.json`
# 3.1 DO NOT touch tubeApi, invapi, invchannel, videourl in `docker/config.json` unless you know what you are doing
# 3.2 As for the others, make sure they're all https in both files
2024-04-22 17:57:50 -04:00
# 3.2 You don't need to touch the other config files unless you know what you are doing
# 4. Run `docker-compose up -d` or `docker compose up -d` (notice the dash)
# 5. Visit your domain in your browser
2024-04-22 17:38:01 -04:00
2022-12-19 12:05:16 -05:00
services:
2024-04-22 17:38:01 -04:00
poketube: # port 6003
# image: quay.io/sudovanilla/poketube
build:
context: .
dockerfile: Dockerfile
depends_on:
- invidious
- lighttube
- january
2022-12-19 12:05:16 -05:00
restart: unless-stopped
volumes:
- ./docker/poke.json:/poketube/config.json:ro
2024-04-22 17:38:01 -04:00
# lighttube - tubeApi
lighttube: # port 80
image: docker.io/kuylar/lighttube:20220711
depends_on:
- mongo
restart: unless-stopped
volumes:
- ./docker/lighttube.yaml:/etc/lighttube.yml:ro
mongo: # port 27017
image: docker.io/mongo:latest
env_file: ./docker/mongo.env
restart: unless-stopped
volumes:
- ./docker/data/mongo:/data/db
# invidious - invapi, invchannel and videourl
invidious: # port 3000
image: quay.io/invidious/invidious:latest
# build:
# context: pokevidious
# dockerfile: docker/Dockerfile
depends_on:
2024-04-22 17:57:50 -04:00
postgres:
condition: service_healthy
2024-04-22 17:38:01 -04:00
restart: unless-stopped
deploy:
replicas: 2 # Adjust number depending on server load
volumes:
- ./docker/invidious.yaml:/invidious/config/config.yml:ro
postgres: # port 5432
image: docker.io/library/postgres:14
env_file: ./docker/postgres.env
restart: unless-stopped
2024-04-22 17:57:50 -04:00
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $POSTGRES_USER"]
interval: 10s
timeout: 5s
retries: 10
2024-04-22 17:38:01 -04:00
volumes:
- ./docker/data/postgres:/var/lib/postgresql/data
- ./pokevidious/config/sql:/config/sql:ro
- ./pokevidious/docker/init-invidious-db.sh:/docker-entrypoint-initdb.d/init-invidious-db.sh:ro
# january - media_proxy
january: # port 7000
# image: ghcr.io/revoltchat/january:latest
build:
context: january
dockerfile: Dockerfile
restart: unless-stopped
# p / pproxy - some kind of proxy idk
pproxy: # port 6014
build:
context: p
dockerfile: Dockerfile
volumes:
- ./docker/pproxy.json:/pproxy/whitelist.json:ro
restart: unless-stopped
# caddy - reverse proxy to connect everything together
caddy: # exposed ports 80, 443 / 8090
image: docker.io/caddy:latest
restart: unless-stopped
volumes:
- ./docker/Caddyfile:/etc/caddy/Caddyfile:ro
- ./docker/data/caddy:/data
2022-12-19 12:05:16 -05:00
ports:
2024-04-22 17:38:01 -04:00
# Notice this is the only service with ports exposed
- 80:80
- 443:443
# If you are running another proxy on the host and the ports are taken
# ... use this instead, and proxy the relevant domains to 127.0.0.1:8090
# Be aware that browsers will refuse
# - 127.0.0.1:8090:80