Skip to content

Repository files navigation

NoxVR

Nox Bot

Load-testing bot for NoxVR relay servers, written in Rust.

CI Rust QUIC Docker License

Part of the NoxVR ecosystem


Overview

NoxVR Bot is a load-testing tool written in Rust that connects to NoxVR relay servers over QUIC, simulating real players to benchmark and stress-test game instances.

Features

  • QUIC transport — encrypted, low-latency connections via quinn
  • Configurable bot count — spawn any number of concurrent simulated players
  • Multiple movement patterns — circular, random teleport, square
  • Voice playback & capture — send .opus files or listen to incoming audio
  • RSA authentication — reuses the NoxVR client credentials
  • Graceful shutdown — clean teardown on Ctrl+C

Quick start (Docker)

The easiest way to run the bot is with Docker Compose:

  1. Configure the target instance in a .env file
  2. Place your Nox credentials in the correct folder
  3. Run docker compose up

Prerequisites

  • Docker + Docker Compose v2 installed
  • Nox credentials (generated by the Nox client when you log in to an account)

1. Configure .env

Copy .env.example to .env and adjust the values:

# Instance to join: <instance_id>@<server>
[email protected]

# Mode: 'listen' (receive + play voice) or 'play' (send an .opus file)
NOX_MODE=listen

# Bot index that listens (MODE=listen)
NOX_LISTEN_ID=0

# Connect as a regular user (skips the AUTHORIZE_BOT check)
NOX_HUMAN=1

# Number of bots / movement mode
NOX_COUNT=1
NOX_MOVEMENT=none

# Log level
NOX_RUST_LOG=info,noxbot=debug,noxrelay=info,nox_api=debug

⚠️ .env holds your local configuration: do not commit it. It is already listed in .gitignore.

2. Credentials (.nox folder)

The bot needs 3 files, normally generated by the Nox client when you log in:

  • config.json — account configuration
  • public_key.pem — RSA public key
  • private_key.pem — RSA private key

Expected config.json format:

{
  "server": "hactazia.fr",
  "servers": {
    "hactazia.fr": {
      "user_id": 12345,
      "gateway": "https://hactazia.fr",
      "_token": "..."
    }
  }
}

The server field must match the part after the @ in NOX_INSTANCE (e.g. [email protected]server = hactazia.fr).

The folder location depends on your OS:

OS .nox folder
Windows %APPDATA%\.noxC:\Users\<user>\AppData\Roaming\.nox
Linux ~/.config/nox

3. Run on Windows

  1. Make sure Docker Desktop (with WSL 2) is installed.
  2. Make sure your credentials are in C:\Users\<user>\AppData\Roaming\.nox.
  3. From the project root:
docker compose up --build

The Windows mount is already configured in docker-compose.yml:

volumes:
  - $APPDATA/.nox:/nox:ro   # windows

4. Run on Linux

  1. Make sure Docker and the Compose plugin are installed.
  2. Make sure your credentials are in ~/.config/nox.
  3. Edit docker-compose.yml: comment the Windows line and uncomment the Linux line:
volumes:
  # - $APPDATA/.nox:/nox:ro          # windows
  - $HOME/.config/nox:/nox:ro # linux
  1. Start the bot:
docker compose up --build

5. Play audio (Linux only)

To hear --listen audio through the host speakers, uncomment the devices section in docker-compose.yml:

devices:
  - /dev/snd:/dev/snd

Useful options

  • Run in the background — uncomment restart: unless-stopped or run docker compose up -d.
  • View logsdocker compose logs -f.
  • Stopdocker compose down.

Building from source

# Development build
cargo build

# Release build (optimized)
cargo build --release

# Run
cargo run --release --bin noxbot -- --count 10 --movement circular

Project structure

  • relay/ — QUIC relay client library
  • test/ — load-testing application (noxbot binary)
  • api/ — API client

Made with ♥ by AtelierVR  ·  AGPL-3.0

Part of the NoxVR project — a federated social VR platform

About

Load testing bot for Nox relay servers, written in Rust.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages