# Тестовый/локальный контур: сборка образов из исходников. # Контекст сборки сервисов — корень репозитория: Dockerfile копирует downloader_common/ и свой app.py. x-logging: &default-logging driver: json-file options: max-size: "20m" max-file: "5" x-healthcheck: &default-healthcheck interval: 60s timeout: 10s retries: 3 start_period: 30s # Единая версия yt-dlp для всех сервисов (в Dockerfile тот же default — для ручного docker build). x-build-args: &build-args YTDLP_VERSION: ${YTDLP_VERSION:-2026.10.21} services: bot: build: . image: 192.168.8.174:3000/vrubel/video-bot:${TAG:-latest} container_name: video_download_bot restart: unless-stopped env_file: - .env volumes: - ./video:/app/video - ./data:/app/data:Z network_mode: host logging: *default-logging command: python bot.py admin_bot: image: 192.168.8.174:3000/vrubel/video-bot:${TAG:-latest} container_name: admin_bot restart: unless-stopped env_file: - .env volumes: - ./data:/app/data:Z network_mode: host logging: *default-logging command: python admin_bot.py youtube-downloader: build: context: . dockerfile: youtube-downloader/Dockerfile args: *build-args image: 192.168.8.174:3000/vrubel/video-youtube:${TAG:-latest} container_name: youtube_downloader_service restart: unless-stopped volumes: - ./youtube-downloader/downloads:/app/downloads - ./youtube-downloader/youtube_cookies.txt:/app/youtube_cookies.txt environment: - YOUTUBE_COOKIES_FILE=/app/youtube_cookies.txt - PORT=5557 network_mode: host healthcheck: <<: *default-healthcheck test: ["CMD", "python3", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5557/health', timeout=5)"] logging: *default-logging instagram-downloader: build: context: . dockerfile: instagram-downloader/Dockerfile args: *build-args image: 192.168.8.174:3000/vrubel/video-instagram:${TAG:-latest} container_name: instagram_downloader_service restart: unless-stopped network_mode: host volumes: - ./instagram-downloader/downloads:/app/downloads - ./instagram-downloader/instagram_cookies.txt:/app/instagram_cookies.txt environment: - INSTAGRAM_COOKIES_FILE=/app/instagram_cookies.txt - PORT=5556 healthcheck: <<: *default-healthcheck test: ["CMD", "python3", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5556/health', timeout=5)"] logging: *default-logging vk-downloader: build: context: . dockerfile: vk-downloader/Dockerfile args: *build-args image: 192.168.8.174:3000/vrubel/video-vk:${TAG:-latest} container_name: vk_downloader_service restart: unless-stopped network_mode: host volumes: - ./vk-downloader/downloads:/app/downloads environment: - PORT=5555 - GUNICORN_WORKERS=2 - GUNICORN_THREADS=4 healthcheck: <<: *default-healthcheck test: ["CMD", "python3", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5555/health', timeout=5)"] logging: *default-logging yapfiles-downloader: build: context: . dockerfile: yapfiles-downloader/Dockerfile image: 192.168.8.174:3000/vrubel/video-yapfiles:${TAG:-latest} container_name: yapfiles_downloader_service restart: unless-stopped network_mode: host volumes: - ./yapfiles-downloader/downloads:/app/downloads environment: - PORT=5558 healthcheck: <<: *default-healthcheck test: ["CMD", "python3", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5558/health', timeout=5)"] logging: *default-logging tiktok-downloader: build: context: . dockerfile: tiktok-downloader/Dockerfile args: *build-args image: 192.168.8.174:3000/vrubel/video-tiktok:${TAG:-latest} container_name: tiktok_downloader_service restart: unless-stopped network_mode: host volumes: - ./tiktok-downloader/downloads:/app/downloads environment: - PORT=5559 healthcheck: <<: *default-healthcheck test: ["CMD", "python3", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5559/health', timeout=5)"] logging: *default-logging