README

Audio::Liquidsoap

Interact with the Liquidsoap telnet interface.

image i_github_com_jonathanstowe_audio_liquidsoap_workflows_ci_badge_svg not found

Synopsis


use Audio::Liquidsoap;

my $ls = Audio::Liquidsoap.new;

say "Connected to liquidsoap { $ls.version } up since { DateTime.new($ls.uptime) }";


...

There are more complete examples in the Examples Directory

Description

This provides a mechanism to interact with the Liquidsoap media toolkit and possibly build radio applications with it.

It provides abstractions to interact with the defined Inputs, Outputs, Queues, Playlists and Requests to the extent allowed by the "telnet" or "socket" interface of liquidsoap. There is also a generalised mechanism for sending arbitrary commands to the server, such as those that may have been provided by the liquidsoap server.register function. However it should be borne in mind that you will almost certainly need to still actually write some liquidsoap script in order to declare the things to manipulate.

This supports both the "telnet" (TCP) and "socket" (Unix domain socket,) server interfaces which can be configured as described in the Liquidsoap settings. The Unix domain socket interface is to be preferred for production use as there is no authentication on the server interface.

Installation

You will need to have "liquidsoap" installed on your system in order to be able to use this. Some Linux distributions and some versions of FreeBSD provide it as a package.

If you are on some platform that doesn't provide liquidsoap as a package then you may be able to install it from source.

It's written in OCaml and has lots of dependencies that you are unlikely to already have but it's doable on most platforms. Alternatively there is a docker image want to use that to run the tests, it is described in the README in the repository.

The tests assume that you have liquidsoap installed somewhere in your path and will run an instance on an unused port so as not to interfere with some running instance you may already have. If your liquidsoap is installed somewhere that is not in your path then you can set the environment variable LIQUIDSOAP to the full path of the binary before running the tests.

Assuming you have a working Raku installation you should be able to install this with zef :

# From the source directory

zef install .

# Remote installation

zef install Audio::Liquidsoap

Support

Because of the potential complexity that can be achieved in custom liquidsoap scripts, this almost certainly doesn't cover every possibility in the interface, but if you really need something I have omitted or have other suggestions please raise an issue at github

And I'll see what I can do.

I'm also probably not the best person to ask if you have anything but the most simple questions about liquidsoap itself, which may probably be raised via the liquidsoap website.

Licence

This is free software.

Please see the LICENCE file in the distribution

Ā© Jonathan Stowe 2016 - 2021

Audio::Liquidsoap v0.1.2

Interact with the Liquidsoap command server

Authors

  • Jonathan Stowe

License

Artistic-2.0

Dependencies

File::Which

Provides

  • Audio::Liquidsoap

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.