Rate This Document
Findability
Accuracy
Completeness
Readability

Using Docker

Install and run NebulaGraph using Docker images to achieve out-of-the-box usability.

  1. Download dependencies.
    1
    yum install docker docker-compose docker-engine git make file libev libev-devel gcc wget python3 python3-devel java-1.8.0-openjdk maven
    
  2. Download the docker-compose project.
    1
    2
    git clone -b release-3.8 https://github.com/vesoft-inc/nebula-docker-compose.git
    cd nebula-docker-compose/
    
  3. Start containers based on the configuration file.
    1
    PYTHONNOUSERSITE=1 docker-compose -f docker-compose.yaml up
    

    To run the services in the background, add the -d or --detach parameter.

    1
    PYTHONNOUSERSITE=1 docker-compose -f docker-compose.yaml up -d
    

    To forcibly recreate a container, add the --force-recreate parameter.

    1
    PYTHONNOUSERSITE=1 docker-compose -f docker-compose.yaml up --force-recreate
    

    The images are automatically pulled from Docker Hub.

  4. Enter the console container to test the connection.
    1
    docker exec -it nebula-docker-compose_console_1 /bin/sh
    

    In the container, use nebula-console to connect to the NebulaGraph service.

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    /usr/local/bin/nebula-console -u root -p nebula --address=graphd --port=9669
    (root@nebula) [(none)]> show hosts;
    +-------------+------+----------+--------------+----------------------+------------------------+---------+
    | Host        | Port | Status   | Leader count | Leader distribution  | Partition distribution | Version |
    +-------------+------+----------+--------------+----------------------+------------------------+---------+
    | "127.0.0.1" | 9779 | "ONLINE" | 0            | "No valid partition" | "No valid partition"   | "3.8.0" |
    +-------------+------+----------+--------------+----------------------+------------------------+---------+
    Got 1 rows (time spent 806µs/1.12939ms)
    
    Wed, 10 Jun 2026 11:31:15 UTC
    

    Here, only one Storage node is shown. ONLINE in the Status column indicates that the cluster is connected.