I'm running an Ubuntu server environment with icecast-2.3.2 and ices-0.4.0 to enable internet-radio streaming.
I have a directory with music files, mostly MP3, let's call it /PATH/TO/MUSIC
. I also have directories with jingles and podcasts. /PATH/TO/JINGLES
and /PATH/TO/PODCASTS
.
So far my server is up and running.
What works:
- Creating daily random playlists from the music-directory using a script and a cron-job.
- Running an IceCast2-Server and streaming the playlist file using IceS.
My question now is:
- How to play podcasts and jingles at specific times? For example every full hour a certain jingle, or every Thursday at 8 p.m. a certain podcast?
I've tried to search the internet on this topic but it seems there is no "one final solution" for this radio-automation issue and it also seems a lot of solutions are rather hacky, aren't they?
Keep in mind this is a server environment, solutions with GUI wont help.
I appreciate any hints and experiences on this topic!
Best Answer
AzuraCast: A Self-Hosted Web Radio Manager
Source: https://github.com/AzuraCast/AzuraCast
Azuracast is a self-hosted web radio management suite, including turnkey installer tools and an easy-to-use web app to manage your stations. http://azuracast.com/
Features
With AzuraCast, you can:
Supported Web Radio Software
AzuraCast uses LiquidSoap as an "AutoDJ" to shuffle songs and playlists and provide an always-online radio stream. You can connect to LiquidSoap and broadcast your own live events as a DJ as well.
To broadcast your radio station to the public, AzuraCast supports both of the gold standards in web radio, IceCast (v2.4) and ShoutCast (v2). You can switch which of these your station uses anytime you want.
You can also use AzuraCast as a tool for relaying or collecting listener statistics and other data about stations that AzuraCast doesn't manage.
Supported Operating Systems
There are two ways to install AzuraCast:
Using Docker and Docker Compose (Recommended): This method contains all of the AzuraCast dependencies in prebuilt container images. Updating and installing is faster, and there are far fewer issues with software compatibility. This method works on any computer that supports the latest version of the Docker Engine and Docker Compose; both can be installed as part of the AzuraCast installer script.
Traditional Installation (Ubuntu 16.04 only): From a clean image of Ubuntu, you can install AzuraCast directly onto your server using the included installer scripts, which use Ansible to manage dependencies. Installation and updating are slower using this method, but you have more control over the software once installed. If you have other software installed on your server, it may conflict with AzuraCast, so always start from a clean installation using this method.
We are always looking to expand our compatibility with host operating systems, and we welcome any assistance in building new deployment scripts for other environments.
What's Included with AzuraCast
Whether you're using the traditional installer or Docker containers, AzuraCast depends on the same stack of software to operate:
Installing AzuraCast
Docker Installation (Recommended)
We strongly recommend installing and using AzuraCast via Docker. All of the necessary software packages are built by our automated tools, so installation is as easy as just pulling down the pre-compiled images. There's no need to worry about compatibility with your host operating system, so any host (including Windows and MacOS) will work great out of the box.
Install Docker and Docker Compose Your computer or server should be running the newest version of Docker and Docker Compose. You can use the easy scripts below to install both if you're starting from scratch:
If you're not installing as root, you may be given instructions to add your current user to the Docker group (i.e.
usermod -aG docker $user
). You should log out or reboot after doing this before continuing below.Pull the AzuraCast Docker Compose File
Choose where on the host computer you would like AzuraCast's configuration file to exist on your server.
Inside that directory, run this command to pull the Docker Compose configuration file.
Run the AzuraCast Docker Installer
From the directory that contains your YML configuration file, run these commands:
Setting up HTTPS with LetsEncrypt
AzuraCast now supports full encryption with LetsEncrypt. LetsEncrypt offers free SSL certificates with easy validation and renewal.
First, make sure your AzuraCast instance is set up and serving from the domain you want to use. Then, run the following command to generate a new LetsEncrypt certificate:
You will be prompted to specify your e-mail address and domain name. Validation will happen automatically. Once complete, run this command to tell nginx to use your new LetsEncrypt certificate:
Reload nginx using the command below:
Your LetsEncrypt certificate is valid for 3 months. To renew the certificates, run this command:
Updating with Docker
From inside the base directory where AzuraCast is copied, run the following commands:
Docker Volume Backup and Restore
AzuraCast has utility scripts to allow for easy backup and restoration of Docker volumes.
You can use docker-backup.sh to back up existing volumes. You can specify a custom path as the script's argument. By default, the script will create a file, backup.tar.gz in the app root.
To restore the application's state from this compressed file use docker-restore.sh and provide it with the path of the existing backup file.
Note that the restoration process will replace any existing AzuraCast database or media that exists inside the Docker volumes.
Traditional Installation (Ubuntu 16.04 only)
Note: Some web hosts offer custom versions of Ubuntu that include different software repositories. These may cause compatibility issues with AzuraCast. Many VPS providers are known to work out of the box with AzuraCast (OVH, DigitalOcean, Vultr, etc), and are thus highly recommended if you plan to use the traditional installer.
AzuraCast is optimized for speed and performance, and can run on very inexpensive hardware, from the Raspberry Pi 3 to the lowest-level VPSes offered by most providers.
Since AzuraCast installs its own radio tools, databases and web servers, you should always install AzuraCast on a "clean" server instance with no other web or radio software installed previously.
Execute these commands as the root user to set up your AzuraCast server:
If you cannot directly log in as the root account on your server, try running sudo su before running the commands above.
The installation process will take between 5 and 15 minutes, depending on your internet connection.
Once the terminal-based installation is complete, you can visit your server's public IP address (http://ip.of.your.server/) to finish the web-based setup.
Updating
AzuraCast also includes a handy updater script that pulls down the latest copy of the codebase from Git, flushes the site caches and makes any necessary database updates. Run these commands as any user with sudo permissions: