This is a minimal music bot for Telegram.
It uses youtube-dl
to search and download the video as well as ffmpeg
to extract the audio.
This bot is very similar to TwiN/discord-music-bot, the main difference being that this one does not require streaming, but only uploading the music file to Telegram, making it much less complex.
Environment variable | Description | Required | Default |
---|---|---|---|
TELEGRAM_BOT_TOKEN | Telegram bot token | yes | "" |
MAXIMUM_AUDIO_DURATION_IN_SECONDS | Maximum duration of audio clips in second | no | 480 |
MAXIMUM_ACTIVE_TASKS | Maximum amount of tasks that can be ran in parallel | no | 5 |
If you want to run it locally, you'll need the following applications:
- youtube-dl
- ffmpeg
docker pull twinproduction/telegram-music-bot
Building the Docker image is done as following:
docker build . -t telegram-music-bot
You can then run the container with the following command:
docker run -e TELEGRAM_BOT_TOKEN=secret --name telegram-music-bot telegram-music-bot