How to Install LibreTime on Debian Latest

Introduction

LibreTime is a free and open-source radio automation system that allows users to schedule and broadcast audio content on radio stations. In this tutorial, we will show you how to install LibreTime on Debian Latest.

Prerequisites

Before you start, make sure you have the following prerequisites:

Step 1: Update and Upgrade Packages

Before installing LibreTime, make sure your Debian server is up-to-date. You can do this by running the following commands:

sudo apt-get update
sudo apt-get upgrade

Step 2: Install Dependencies

LibreTime has various dependencies that must be installed on your server. You can install them using the following command:

sudo apt-get install icecast2 liquidsoap liquidsoap-plugin-all apache2 libapache2-mod-php7.4 php7.4 php7.4-cli php7.4-mysql php7.4-curl php7.4-cli php7.4-xml php7.4-mbstring php7.4-fpm php7.4-gd php7.4-zip libav-tools

Step 3: Download and Extract LibreTime

Download the latest version of LibreTime from their website by running the following commands:

cd /tmp
wget https://github.com/LibreTime/libretime/releases/download/v3.1.0/libretime-3.1.0.tar.gz

Once the download is complete, extract the tarball to the /var/www directory with the following command:

sudo tar -xzf libretime-3.1.0.tar.gz -C /var/www/

Step 4: Set Permissions

Set proper permissions to the files and directories in the libretime directory, run the following commands:

sudo chown -R www-data:www-data /var/www/libretime/
sudo chmod -R 777 /var/www/libretime/

Step 5: Create a MySQL Database

Create a new MySQL database and user by running the following commands:

sudo mysql -u root -p

Once logged in, create the LibreTime database and user with the following commands, replacing <password> with a strong password:

CREATE DATABASE libretime;
CREATE USER 'libretime'@'localhost' IDENTIFIED BY '<password>';
GRANT ALL PRIVILEGES ON libretime.* TO 'libretime'@'localhost';
FLUSH PRIVILEGES;
exit

Step 6: Configure Apache to Serve LibreTime

Configure Apache to serve LibreTime by creating a new virtual host file, run the following command:

sudo nano /etc/apache2/sites-available/libretime.conf

Add and replace the following lines:

<VirtualHost *:80>
   ServerAdmin webmaster@localhost
   DocumentRoot /var/www/libretime
   ServerName your-domain.com
   ServerAlias www.your-domain.com
   <Directory "/var/www/libretime">
      AllowOverride All
      Require all granted
   </Directory>
</VirtualHost>

Step 7: Enable the New Virtual Host and Restart Apache

Activate the new virtual host by running the following command:

sudo a2ensite libretime.conf

Finally, restart Apache for the changes to take effect:

sudo systemctl restart apache2

Step 8: Complete the LibreTime Setup

Finally, complete the setup by going to your server's IP address or domain name in your web browser. You will be prompted to enter the database details you created earlier during the setup process.

Congratulations! You have successfully installed LibreTime on Debian Latest. Now you can schedule and broadcast audio content on your radio station.

If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!

Alternatively, for the best virtual desktop, try Shells!