VariantValidator supports two Docker-based installation methods.
| Method | VariantValidator | Supporting Services |
|---|---|---|
| Docker Quick Start | Runs locally | Runs in Docker |
| Full Docker Installation | Runs in Docker | Runs in Docker |
The Docker Quick Start runs the required backend services (Validator database, VVTA, and SeqRepo) in Docker while VariantValidator itself is installed and executed locally within a Conda environment. This is the recommended installation method for users who wish to run VariantValidator directly on their local machine while Docker manages the supporting infrastructure.
The Full Docker Installation runs both VariantValidator and all supporting services inside Docker, providing a completely containerised environment suitable for isolated deployments, reproducible testing, and continuous integration.
Note: Docker images are only built during the initial installation. Once created, the containers can be started and stopped without rebuilding or reinstalling VariantValidator.
The Quick Start installation runs the required backend services in Docker:
- Validator MySQL database
- VVTA PostgreSQL database
- SeqRepo
VariantValidator itself is installed and executed locally within a Conda environment.
- Docker
- Conda (Miniconda or Anaconda)
- Git
git clone https://github.com/openvar/VariantValidator.git
cd VariantValidatordocker network create variantvalidator-networkdocker build \
--no-cache \
-f db_dockerfiles/vvta/Dockerfile \
-t postgres-vvta \
db_dockerfiles/vvta
docker run -d \
--name vv-vvta \
--network variantvalidator-network \
--shm-size=2g \
-p 54320:5432 \
postgres-vvtadocker build \
--no-cache \
-f db_dockerfiles/vdb/Dockerfile \
-t mysql-validator \
db_dockerfiles/vdb
docker run -d \
--name vv-vdb \
--network variantvalidator-network \
-p 33060:3306 \
mysql-validatordocker build \
--no-cache \
-f db_dockerfiles/vvsr/Dockerfile \
-t seqrepo-validator \
db_dockerfiles/vvsrCreate a temporary container and copy the SeqRepo data to the host.
sudo mkdir -p /usr/local/share/seqdata
docker create \
--name vv-seqrepo-temp \
seqrepo-validator
sudo docker cp \
vv-seqrepo-temp:/usr/local/share/seqdata/. \
/usr/local/share/seqdata
docker rm vv-seqrepo-tempThe directory should contain the extracted SeqRepo data.
ls /usr/local/share/seqdataWait until the database containers have completed their initialisation before continuing.
Run this command until you see the message "MySQL ready."
until docker exec vv-vdb \
mysqladmin ping \
-u vvadmin \
-pvar1ant \
--silent
do
sleep 5
done
echo "MySQL ready."Run this command until you see the message "VVTA ready."
until docker logs vv-vvta 2>&1 | \
grep -q "PostgreSQL init process complete; ready for start up."
do
sleep 10
done
echo "VVTA ready."conda env create -f environment.ymlconda activate vvenvcp configuration/docker-local.ini ~/.variantvalidatorpip install .python -m VariantValidator.bin.setup_lovd_syntax_checkerVariantValidator is now installed and ready to use.
Run the test suite locally against the Docker-hosted backend services:
pytest \
-n 4 \
testsThe Full Docker Installation runs both VariantValidator and its supporting services entirely within Docker.
Complete the following sections from the Docker Quick Start:
- Create a Docker network
- Build and start the VVTA PostgreSQL database
- Build and start the Validator MySQL database
- Build and start SeqRepo
- Wait for the databases to initialise
docker build \
--no-cache \
-t variantvalidator \
.docker run -d \
--name variantvalidator \
--network variantvalidator-network \
--volumes-from vv-seqrepo:ro \
variantvalidatorRun the test suite directly:
docker exec variantvalidator \
pytest \
-n 4 \
testsAlternatively, open an interactive shell within the container:
docker exec -it variantvalidator bashThen, from within the container, run:
pytest \
-n 4 \
testsOnce the Docker images and containers have been created, they can be restarted without repeating the installation steps.
Start the supporting services:
docker start vv-vvta vv-vdb vv-seqrepoWait a few moments for the database services to initialise, then activate the Conda environment:
conda activate vvenvVariantValidator is now ready to use.
Start all containers:
docker start vv-vvta vv-vdb vv-seqrepo variantvalidatorWait a few moments for the services to initialise.
VariantValidator is now ready to use.
docker stop vv-vvta vv-vdb vv-seqrepodocker stop variantvalidator vv-seqrepo vv-vdb vv-vvtaTo completely remove the installation, stop and remove the containers, then remove the Docker network.
docker stop variantvalidator vv-seqrepo vv-vdb vv-vvta || true
docker rm variantvalidator vv-seqrepo vv-vdb vv-vvta || true
docker network rm variantvalidator-network || trueThe Docker images are retained and can be reused the next time you start VariantValidator. To completely remove the installation, including the Docker images, run:
docker rmi variantvalidator seqrepo-validator mysql-validator postgres-vvta