tortoise-tts/scripts/run_docker.sh
Gareth Davidson 097f379c2d Add a docker_data dir and improve caching
Rather than relying on things outside the project dir, have a
data dir with all the caches, model files etc, and exclude them from
git and the docker context with the .ignore files.

Also move the install step to last and put it in its own step, so it
doesn't have to rebuild all the slow conda stuff every time there's
a change to a file in the project.
2023-09-14 08:24:15 +01:00

16 lines
320 B
Bash
Executable file

#!/bin/bash
set -e
docker build . -t tts
pwd=$(pwd)
docker run --gpus all \
-e TORTOISE_MODELS_DIR=/models \
-v $pwd/docker_data/models:/models \
-v $pwd/docker_data/results:/results \
-v $pwd/docker_data/.cache/huggingface:/root/.cache/huggingface \
-v $pwd/docker_data/work:/work \
-it tts