nevetsCotsu is a self-hosted discord music bot. It was a solo personal project that was born out of both curiousity and practical necessity.

Features:

  • A music player that supports play, pause, stop, seeking, looping, and now-playing information.
  • Support for Youtube Videos via Youtube Link or Youtube Search.
  • Song queueing, queue manipulation (song insertion, removal, order swapping).
  • Mutli-server support.
  • Per-server volume control.

nevetsCotsu was developed in C# within the .NET framework. It uses the Discord.NET framework for communication with Discord’s servers, FFMPEG for audio processing and streaming, and YTExplode for Youtube crawling. Since the project was meant for simple personal use, it doesn’t use a dedicated database, instead using in-memory structures to maintain multi-server song queue data.

During the development of this project, I configured a GitHub CI/CD pipeline that involved containerized-builds with Docker, automatic image upload to Docker Hub, and deployment to an AWS EC2 instance. The AWS EC2 instance was later updated to a single-instance EC2 scaling group to add automatic failure recovery, as well as minimize downtime when updating the discord bot.

  • The EC2 instance has since then been terminated (to prevent recurring costs that come with cloud hosting) and is locally spun-up when desired.

The application is fully asychronousous and includes sychronization to ensure correctness of music player and music queue state even when processing rapid same-server commands.

GitHub: https://github.com/nevetsosu/nevetsCotsu