Skip to main content
Version: Stable 4.x

Install using docker

This guide walk you though the steps required to install LibreTime on your system using docker.

Before installing

Before installing LibreTime, you need to make sure that Docker is installed on your operating system and up-to-date.


First, set the version you want to install:

echo LIBRETIME_VERSION="4.0.0" > .env

Download the docker-compose files from the repository:

source .env

wget "$LIBRETIME_VERSION/docker-compose.yml"
wget "$LIBRETIME_VERSION/docker/nginx.conf"
wget "$LIBRETIME_VERSION/docker/config.template.yml"

The config.template.yml configuration file you downloaded already contains specific values required by the container setup, you shouldn't change them:

host: "postgres"
password: ${POSTGRES_PASSWORD} # The value will be substituted
host: "rabbitmq"
password: ${RABBITMQ_DEFAULT_PASS} # The value will be substituted
liquidsoap_host: "liquidsoap"
server_listen_address: ""
host: "icecast"
source_password: ${ICECAST_SOURCE_PASSWORD} # The value will be substituted
admin_password: ${ICECAST_ADMIN_PASSWORD} # The value will be substituted

Setup LibreTime

Once the files are downloaded, generate a set of random passwords for the different docker services used by LibreTime:

echo "# Postgres
POSTGRES_PASSWORD=$(openssl rand -hex 16)

# RabbitMQ
RABBITMQ_DEFAULT_PASS=$(openssl rand -hex 16)

# Icecast
ICECAST_SOURCE_PASSWORD=$(openssl rand -hex 16)
ICECAST_ADMIN_PASSWORD=$(openssl rand -hex 16)
ICECAST_RELAY_PASSWORD=$(openssl rand -hex 16)" >> .env

Generate a configuration file from the ./config.template.yml template with the previously generated passwords:

bash -a -c "source .env; envsubst < config.template.yml > config.yml"

On Debian based systems, if the envsubst command isn't found you can install it with:

sudo apt install gettext-base

Next, edit the configuration file at ./config.yml to fill required information and to match your needs.


You can find more details in the docker-compose.yml file or on the external services docker specific documentation:

Next, run the following commands to setup the database:

docker-compose run --rm api libretime-api migrate

Finally, start the services, and check that they're running using the following commands:

docker-compose up -d

docker-compose ps
docker-compose logs -f

Securing LibreTime

Once LibreTime is running, it's recommended to install a reverse proxy to setup SSL termination and secure your installation.

First login

Once the setup is completed, log in the interface (with the default user admin and password admin), and edit the project settings (go to Settings > General) to match your needs.


Remember to change your password.