Prerequisites

Before installing yb-voyager in Docker, ensure that you have the following:

  1. Docker runtime installed on your machine.
  2. Docker is configured to run without sudo (recommended). Refer to Manage Docker as a non-root user in the Docker documentation.

Install

Perform the following steps to install yb-voyager:

  1. Pull the docker image from YugabyteDB's docker hub (pull the version from docker.io) as follows:

    docker pull software.yugabyte.com/yugabytedb/yb-voyager
    
  2. Run yb-voyager using one of the following methods:

    Method 1: Use the Wrapper script

    1. Download the script to run yb-voyager using the docker image from yb-voyager's GitHub repository, and move it to your machine's bin directory using the following commands:

      wget -O ./yb-voyager https://raw.githubusercontent.com/yugabyte/yb-voyager/main/docker/yb-voyager-docker && \
      chmod +x ./yb-voyager && \
      sudo mv yb-voyager /usr/local/bin/yb-voyager
      
    2. Verify the installation:

      yb-voyager version
      

    Limitations:

    Method 2: Use the Container directly

    Run the container directly with volume mounts.

    1. Run the container with an interactive shell:

      docker run -it --rm \
        --network=host \
        -v /path/to/export-dir/on/host:/home/ubuntu/export-dir \
        yugabytedb/yb-voyager bash
      
    2. Once inside the container, run any yb-voyager command. For example, to verify the installation:

      yb-voyager version
      

      Mount directories

      Mount all directories that yb-voyager needs to access (export directory, configuration files, SSL certificates, and so on). On macOS, add --platform=linux/amd64 to the docker run command.