Skip to content

Add Dockerfiles and Docker examples#30

Draft
xashr wants to merge 2 commits into
0xShug0:release-0.1from
xashr:docker_and_examples_pr
Draft

Add Dockerfiles and Docker examples#30
xashr wants to merge 2 commits into
0xShug0:release-0.1from
xashr:docker_and_examples_pr

Conversation

@xashr

@xashr xashr commented Jul 5, 2026

Copy link
Copy Markdown

Summary

Docker support for audio.cpp is currently limited and focused on development (see Docker.md).

This PR adds Docker support to help users get started quickly. It provides:

  • Multi-stage Dockerfiles (CPU and CUDA) with separate build and runtime stages
    • Inspired by llama.cpp (hence the .devops folder naming)
    • "Full" images with all binaries and the multiplexer (similar to llama.cpp's full images)
  • Ready-to-run examples for Pocket TTS (CPU & CUDA)
    • CLI: run Pocket TTS via docker run
    • Server: run Pocket TTS via Docker Compose

Tested on Ubuntu Linux with an RTX 5090 and an Intel CPU.

Quick Start

CLI:

  1. Download Pocket TTS models into the examples/docker/models/ folder
  2. Run from repo root: docker build -f .devops/cuda.Dockerfile -t local/audiocpp:full-cuda .
  3. Run ./cuda-tts.sh to generate speech

Server:

  1. Download Pocket TTS models into the examples/docker/models/ folder
  2. Run docker compose -f cuda-server.yml up
  3. Run ./tts.sh to generate speech via a curl request

Known Issues

  • The audio.cpp server does not terminate gracefully. The container cannot be stopped cleanly and must be killed (e.g. press Ctrl+C twice with Docker Compose). Proper signal handling is needed in the server.

Todo

Some open tasks before merging:

  • Extend main documentation regarding Docker build and Docker examples
  • Decide on naming convention for docker images (e.g. audiocpp vs audio.cpp)
  • (Support Vulkan)

@xashr xashr marked this pull request as draft July 5, 2026 18:10
@xashr xashr force-pushed the docker_and_examples_pr branch from 5b6b9d6 to 796a6f6 Compare July 5, 2026 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant