services: api: image: ghcr.io/alertua/styletts2-ukrainian-openai-tts-api:latest container_name: ${CONTAINER_PREFIX}api env_file: - .env ports: # host_port:container_port - ${UVICORN_PORT}:${UVICORN_PORT} depends_on: gradio: condition: service_healthy gradio: image: ghcr.io/alertua/patriotyk_styletts2_ukrainian_docker:latest container_name: ${CONTAINER_PREFIX}gradio env_file: - .env ports: # host_port:container_port - ${GRADIO_SERVER_PORT}:${GRADIO_SERVER_PORT} volumes: # host_path:container_path - ./${CONTAINER_PREFIX}data:/data healthcheck: test: python -c "import sys, http.client; c=http.client.HTTPConnection('127.0.0.1', ${GRADIO_SERVER_PORT}, timeout=5); c.request('HEAD', '/'); r=c.getresponse(); sys.exit(0 if r.status==200 else 1)" interval: 15s timeout: 5s start_period: 3s retries: 100 # # uncomment this block to use the NVIDIA GPU # deploy: # resources: # reservations: # devices: # - driver: nvidia # count: 1 # capabilities: [gpu]