1#!/usr/bin/liquidsoap
2# Playlist
3i_playlist = crossfade(
4 duration=3.0,
5 blank.eat(
6 start_blank=true,
7 max_blank=1.0,
8 threshold=-45.0,
9 playlist(
10 mode="randomize",
11 reload=1,
12 reload_mode="rounds",
13 "/music"
14 )
15 )
16)
17
18# Make it safe
19radio = mksafe(i_playlist)
20
21# Output
22output.icecast(
23 %mp3(
24 bitrate=128,
25 id3v2=true
26 ),
27 name=environment.get("STREAM_NAME", default="Radio"),
28 description=environment.get("STREAM_DESC", default="Our selection of music"),
29 url=environment.get("STREAM_URL"),
30 mount=environment.get("STREAM_MOUNTPOINT", default="live"),
31 password=environment.get("ICECAST_SOURCE_PASSWORD", default="hackme"),
32 host="icecast",
33 port=8000,
34 encoding="UTF-8",
35 radio
36)