A robust Discord music bot featuring YouTube & Spotify support, a modern controller UI
999
Quick links:
AuroraMusic is a feature-rich music bot designed for Discord servers, allowing users to play music from various sources, manage queues, and interact with an intuitive user interface. This bot supports both YouTube and Spotify, providing a seamless music experience for users.
Windows (local):
git clone https://github.com/Soham-Das-afk/AuroraMusic.git
cd AuroraMusic
python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
Copy-Item .env.example .env
# edit .env to set BOT_TOKEN and ALLOWED_GUILD_IDS; set YOUTUBE_COOKIES=cookies/youtube.txt (recommended)
# Optional: Create valid_proxies.txt in root if you need proxies
python src/bot.py
Linux (local):
git clone https://github.com/Soham-Das-afk/AuroraMusic.git
cd AuroraMusic
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env
# edit .env to set BOT_TOKEN and ALLOWED_GUILD_IDS; set YOUTUBE_COOKIES=cookies/youtube.txt (recommended)
# Optional: Create valid_proxies.txt in root if you need proxies
python3 src/bot.py
Docker (both OS):
# ensure .env exists and is filled; cookies recommended at cookies/youtube.txt
# Optional: Create valid_proxies.txt in root if you need proxies
docker compose up -d --build
docker compose logs -f
Run directly with Docker (without Compose):
Windows PowerShell
# assumes you created and filled .env in the project folder
docker pull sohamdas103/auroramusic:latest
docker run --name auroramusic ^
--env-file .env ^
-v "$PWD/cookies:/app/src/cookies:ro" ^
-v "$PWD/data:/app/src/data" ^
-v "$PWD/valid_proxies.txt:/app/valid_proxies.txt:ro" ^
-p 8080:8080 ^
-d sohamdas103/auroramusic:latest
Linux/macOS
# assumes you created and filled .env in the project folder
docker pull sohamdas103/auroramusic:latest
docker run --name auroramusic \
--env-file .env \
-v "$(pwd)/cookies:/app/src/cookies:ro" \
-v "$(pwd)/data:/app/src/data" \
-v "$(pwd)/valid_proxies.txt:/app/valid_proxies.txt:ro" \
-p 8080:8080 \
-d sohamdas103/auroramusic:latest
valid_proxies.txt file to bypass regional restrictions.Once the bot is up and running:
Use /setup to create a dedicated music controller channel in your server.
In the controller channel:
Helpful slash commands:
/help — quick usage guide and links to your controller channel/ping — bot latency/status (shows AuroraMusic v4.3.4)/health — configuration and queue summary/cleanup — remove the controller (admin only)Permissions note:
Install prerequisites
winget install Gyan.FFmpeg
choco install ffmpeg
python --version
ffmpeg -version
Get the code and set up a virtual environment
git clone https://github.com/Soham-Das-afk/AuroraMusic.git
cd AuroraMusic
python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
Configure environment
Copy-Item .env.example .env
.env and set:
Run the bot
python src/bot.py
In Discord, run /setup in a server you own to create the music controller channel.
Tip: If venv activation is blocked, run PowerShell as admin once and execute:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
Install prerequisites (Debian/Ubuntu example)
sudo apt update
sudo apt install -y python3 python3-venv python3-pip ffmpeg libopus0 libsodium23
python3 --version
ffmpeg -version
Get the code and set up a virtual environment
git clone https://github.com/Soham-Das-afk/AuroraMusic.git
cd AuroraMusic
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Configure environment
cp .env.example .env
.env and set BOT_TOKEN, ALLOWED_GUILD_IDS, and any optional values.Run the bot
python3 src/bot.py
Use /setup in your server to create the music controller.
Required:
BOT_TOKEN — your Discord bot tokenALLOWED_GUILD_IDS — comma-separated list of server IDs where the bot is allowedOptional:
SPOTIFY_CLIENT_ID, SPOTIFY_CLIENT_SECRET — enable Spotify featuresYOUTUBE_COOKIES — (recommended) path to cookies file (e.g., cookies/youtube.txt) to help bypass age or regional restrictions and improve reliabilityBOT_BANNER_URL — optional fallback image/GIF URL for the welcome banner if your Discord App doesn’t have a banner (example: https://cdn.example.com/banner.gif)CONTROLLER_THUMBNAIL_URL — optional controller thumbnail image URL (not shown by default; can be enabled later)SHOW_BANNER — show the welcome banner image card (true/false; accepts 1/0, true/false, yes/no, y/n)SHOW_CONTROLLER_THUMBNAIL — show a small thumbnail on controller embeds (true/false; accepts 1/0, true/false, yes/no, y/n)OWNER_CONTACT — contact string shown for unauthorized guilds (e.g., Discord handle/ID)PROXY_URL — optional single proxy URL (e.g., http://user:pass@host:port)PROXY_FILE — optional path to a text file containing one proxy per line (default: valid_proxies.txt in project root)AUTO_RESTART_ENABLED — enable daily auto-restart (true/false, default true)AUTO_RESTART_TIME — time for restart in HH:MM (default 06:00)AUTO_RESTART_TZ_OFFSET_MINUTES — timezone offset in minutes (IST=330)CLEAR_CACHE_ON_START — (removed) on-disk cache and background downloads are disabled; this option is deprecated in this build.ENABLE_GLOBAL_COMMAND_SYNC — allow global slash-command sync (true/false; default: false). Use with care to avoid rate limits.COMMAND_SYNC_RETRIES — number of retries for command sync attempts (default: 3)COMMAND_SYNC_BACKOFF_BASE — exponential backoff base for command sync retries (default: 1.5; delay = base ** attempt)GLOBAL_COMMAND_SYNC_OFFPEAK_ENABLED — if true, global command syncing will be deferred to an off-peak UTC window (default: false)GLOBAL_COMMAND_SYNC_OFFPEAK_START_HOUR_UTC — start hour (UTC) for off-peak window (0–23; default: 2)GLOBAL_COMMAND_SYNC_OFFPEAK_END_HOUR_UTC — end hour (UTC) for off-peak window (0–23; default: 5)If your Discord App banner isn’t set or you prefer a custom GIF, set BOT_BANNER_URL to a direct image URL. Reliable, no-login choices:
https://i.ibb.co/xxxx/banner.gif (note the i.ibb.co host and file extension)BOT_BANNER_URL in .env to that direct linkTip: Avoid page/album links (they return HTML). You want links ending in .gif, .png, or .jpg with Content-Type: image/*.
Build the image and run with Docker Compose (recommended):
.env includes the required variables listed above.AuroraMusic/cookies/youtube.txt and set YOUTUBE_COOKIES=cookies/youtube.txt in .env (helps bypass age/region restrictions).valid_proxies.txt in the root folder if you need proxy support.docker compose up -d --build
docker compose logs -f
Notes:
./cookies -> /app/src/cookies:ro./data -> /app/src/data./valid_proxies.txt -> /app/valid_proxies.txt:ro (if it exists)docker compose down
linux/amd64 and linux/arm64 (Apple Silicon, Graviton, etc.). Docker will automatically pull the correct architecture manifest..env (copy from .env.example).AuroraMusic/cookies/youtube.txt and set YOUTUBE_COOKIES=cookies/youtube.txt in .env (bypasses age or regional access limits).valid_proxies.txt in the root folder if you need proxies.docker compose up -d --build
docker compose logs -f
docker compose down
sudo apt update
sudo apt install -y docker.io docker-compose-plugin
sudo usermod -aG docker $USER
newgrp docker
docker compose version
valid_proxies.txt if needed..env and cookies as above.docker compose up -d --build
docker compose logs -f
docker compose down
docker compose pull
docker compose up -d --pull always
docker pull sohamdas103/auroramusic:latest
docker stop auroramusic && docker rm auroramusic
# re-run the docker run command from above
git pull
pip install -r requirements.txt
python src/bot.py
BOT_TOKEN in .env and that the bot was invited with the right scopes (bot + applications.commands).ffmpeg -version works in your shell/terminal. Install FFmpeg and add to PATH.libopus0 and libsodium are installed (see Linux prerequisites).I maintain this project when it’s needed or when I get time. If you run into issues or have suggestions, feel free to reach out directly:
This project uses a source-available license tailored for AuroraMusic.
See the LICENSE file for the full terms.
Content type
Image
Digest
sha256:335bdbbc9…
Size
337.5 MB
Last updated
8 months ago
docker pull sohamdas103/auroramusic