yt-dlp-dags/docker-compose-ytdlp-ops.yaml

68 lines
1.9 KiB
YAML

version: '3.8'
services:
camoufox:
build:
context: ./camoufox # Path relative to the docker-compose file
dockerfile: Dockerfile
ports:
# Optionally expose the camoufox port to the host for debugging
# - "12345:12345"
- "12345" # Expose port within the docker network, pass in Dockerfile
- "5900:5900" # Expose VNC port to the host
networks:
- airflow_prod_proxynet
command: [
"--ws-host", "0.0.0.0",
"--port", "12345",
"--ws-path", "mypath",
"--proxy-url", "socks5://sslocal-rust-1082:1082",
"--locale", "en-US",
"--geoip",
"--extensions", "/app/extensions/google_sign_in_popup_blocker-1.0.2.xpi,/app/extensions/spoof_timezone-0.3.4.xpi,/app/extensions/youtube_ad_auto_skipper-0.6.0.xpi"
]
restart: unless-stopped
# Add healthcheck if desired
ytdlp-ops:
image: pangramia/ytdlp-ops-server:latest # Don't comment
depends_on:
- camoufox # Ensure camoufox starts first
ports:
- "9090:9090" # Main RPC port
- "9091:9091" # Health check port
volumes:
- context-data:/app/context-data
networks:
- airflow_prod_proxynet
command:
- "--script-dir"
- "/app/scripts"
- "--context-dir"
- "/app/context-data"
- "--port"
- "9090"
- "--clients"
# Add 'web' client since we now have camoufox
- "web,ios,android,mweb"
- "--proxy"
- "socks5://sslocal-rust-1082:1082"
# Add the endpoint argument pointing to the camoufox service
- "--endpoint"
- "ws://camoufox:12345/mypath"
- "--probe"
# Add --camouflage-only if you don't want ytdlp-ops to manage the browser directly
- "--camouflage-only"
# Add flag to print full tokens in logs by default
- "--print-tokens"
restart: unless-stopped
pull_policy: always
volumes:
context-data:
name: context-data
networks:
airflow_prod_proxynet:
external: true