A self-hostable Discord music bot, focused on fairness.
Note
Λύρα is actively developed with a strong focus on maintaining stability. Core functionality is fully implemented, but some features (e.g., queue visualisation, command fairness polls) are still under development. Users are encouraged to self-host and test locally.
Start by creating your environment configuration:
$ cp .env.example .env
Edit .env
and provide the required values:
BOT_TOKEN
(Discord bot token)- Database credentials
- Lavalink credentials
Comments in the file will guide you through the configuration.
The easiest way to run Λύρα is via Docker. Begin by copying the example Compose file:
$ cp compose.example.yaml compose.yaml
Next, set up two directories for persistent storage (PostgreSQL data and Lavalink plugins) and update your .env
:
$ mkdir -p /path/to/your/database
$ mkdir -p /path/to/your/plugins
# chown -R 322:322 /path/to/your/plugins
Update .env
:
DOCKER_POSTGRES_PATH=/path/to/your/database
DOCKER_LAVALINK_PLUGINS_PATH=/path/to/your/plugins
Start the bot and services:
# docker compose up -d
- View logs:
# docker compose logs -f
- Stop services:
# docker compose down
If you're using nix-direnv
, enter the dev shell automatically; otherwise, run:
$ nix develop --no-pure-eval
This sets up all dependencies. Then, start the required services:
$ devenv up -D
- Attach to logs:
$ process-compose attach
- Stop services:
$ process-compose down
- Run the bot:
$ cargo run --release
To set up manually, install:
Follow their official documentation for configuration. Then:
$ cargo run --release
- twilight-rs - Scalable Rust libraries for Discord API.
- Lavalink - Standalone audio node based on Lavaplayer.
- lavalink-rs - Async Lavalink bindings for Rust Discord libraries.