diff --git a/docker-compose.yml b/docker-compose.yml index 4ac9551..0138c8a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -8,7 +8,7 @@ services: - ./state/liquidsoap/playlists:/playlists - ./state/liquidsoap/data:/data - /etc/localtime:/etc/localtime:ro - command: /bin/bash -xc 'env; liquidsoap -v --debug /config/main.liq' + command: /bin/bash -xc 'env; liquidsoap -v --debug /config/debug.liq' environment: - HARBOR_PASSWORD=MGT7aEqP - LIVE_PASSWORD=fuckyoujoa diff --git a/state/liquidsoap/config/debug.liq b/state/liquidsoap/config/debug.liq new file mode 100644 index 0000000..e5d9713 --- /dev/null +++ b/state/liquidsoap/config/debug.liq @@ -0,0 +1,41 @@ +set("log.file",false) +set("log.stdout",true) + +set("server.telnet",true) +set("server.telnet.port", 5000) +set("server.telnet.bind_addr", "0.0.0.0") + +set("decoder.file_extensions.gstreamer",["wav", "webm"]) +set("decoder.mime_types.gstreamer",["audio/x-wav", "audio/wav", "video/webm"]) + +def crossfade(a,b) + add(normalize=false, + [ sequence([ blank(duration=5.), + fade.initial(duration=5.,b) ]), + fade.final(duration=5.,a) ]) +end + +live = audio_to_stereo( + rewrite_metadata( + [ + ("title", "$(title) (LIVE - Dodsorfas Radio)"), + ("comment", "http://www.radio.dodsorf.as") + ], + stretch( + ratio=interactive.float("test", 1.00005), + input.harbor( + "dodsorfas.live", + id="dodsorfas.live", + port=5002, + password=getenv("LIVE_PASSWORD"), + user="source", + logfile="/tmp/harbor.log" + ) + ) + ) +) + +DanDubstepThingies = "/playlists/Daniel/Dan - dubstepthingies.m3u" + +randomsong = random(playlist(conservative=true, DanDubstepThingies)) +count = list.length(playlist.parse(DanDubstepThingies)) \ No newline at end of file diff --git a/state/liquidsoap/config/main.liq b/state/liquidsoap/config/main.liq index 6fe9cc6..769feac 100644 --- a/state/liquidsoap/config/main.liq +++ b/state/liquidsoap/config/main.liq @@ -113,62 +113,62 @@ Halloween = "/playlists/events/Halloween.m3u" ## END PLAYLISTS -randomsong = playlist(conservative=true, JoakimDiverse) +randomsong = random(playlist(conservative=true, JoakimDiverse)) count = list.length(playlist.parse(JoakimDiverse)) -randomsong = random(weights=[list.length(playlist.parse(AlternativeJoa)), count], [playlist(conservative=true, AlternativeJoa), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(AlternativeJoa)), count], [playlist(AlternativeJoa), randomsong]) count = count + list.length(playlist.parse(AlternativeJoa)) -randomsong = random(weights=[list.length(playlist.parse(DanAwesome)), count], [playlist(conservative=true, DanAwesome), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DanAwesome)), count], [playlist(DanAwesome), randomsong]) count = count + list.length(playlist.parse(DanAwesome)) -randomsong = random(weights=[list.length(playlist.parse(DanDontStarve1)), count], [playlist(conservative=true, DanDontStarve1), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DanDontStarve1)), count], [playlist(DanDontStarve1), randomsong]) count = count + list.length(playlist.parse(DanDontStarve1)) -randomsong = random(weights=[list.length(playlist.parse(DanDubstepThingies)), count], [playlist(conservative=true, DanDubstepThingies), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DanDubstepThingies)), count], [playlist(DanDubstepThingies), randomsong]) count = count + list.length(playlist.parse(DanDubstepThingies)) -randomsong = random(weights=[list.length(playlist.parse(DanEdgyMusicYT)), count], [playlist(conservative=true, DanEdgyMusicYT), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DanEdgyMusicYT)), count], [playlist(DanEdgyMusicYT), randomsong]) count = count + list.length(playlist.parse(DanEdgyMusicYT)) -randomsong = random(weights=[list.length(playlist.parse(DanElectronicRealMusic)), count], [playlist(conservative=true,DanElectronicRealMusic), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DanElectronicRealMusic)), count], [playlist(DanElectronicRealMusic), randomsong]) count = count + list.length(playlist.parse(DanElectronicRealMusic)) -randomsong = random(weights=[list.length(playlist.parse(TaylorSwift)), count], [playlist(conservative=true, TaylorSwift), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(TaylorSwift)), count], [playlist(TaylorSwift), randomsong]) count = count + list.length(playlist.parse(TaylorSwift)) -randomsong = random(weights=[list.length(playlist.parse(AstridS)), count], [playlist(conservative=true, AstridS), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(AstridS)), count], [playlist(AstridS), randomsong]) count = count + list.length(playlist.parse(AstridS)) -randomsong = random(weights=[list.length(playlist.parse(Coldplay)), count], [playlist(conservative=true, Coldplay), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(Coldplay)), count], [playlist(Coldplay), randomsong]) count = count + list.length(playlist.parse(Coldplay)) -randomsong = random(weights=[list.length(playlist.parse(DemiLovato)), count], [playlist(conservative=true, DemiLovato), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(DemiLovato)), count], [playlist(DemiLovato), randomsong]) count = count + list.length(playlist.parse(DemiLovato)) -randomsong = random(weights=[list.length(playlist.parse(KatyPerry)), count], [playlist(conservative=true, KatyPerry), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(KatyPerry)), count], [playlist(KatyPerry), randomsong]) count = count + list.length(playlist.parse(KatyPerry)) -randomsong = random(weights=[list.length(playlist.parse(SelenaGomez)), count], [playlist(conservative=true, SelenaGomez), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(SelenaGomez)), count], [playlist(SelenaGomez), randomsong]) count = count + list.length(playlist.parse(SelenaGomez)) -randomsong = random(weights=[list.length(playlist.parse(ShawnMendes)), count], [playlist(conservative=true, ShawnMendes), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(ShawnMendes)), count], [playlist(ShawnMendes), randomsong]) count = count + list.length(playlist.parse(ShawnMendes)) -randomsong = random(weights=[list.length(playlist.parse(ZaraLarsson)), count], [playlist(conservative=true, ZaraLarsson), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(ZaraLarsson)), count], [playlist(ZaraLarsson), randomsong]) count = count + list.length(playlist.parse(ZaraLarsson)) -randomsong = random(weights=[list.length(playlist.parse(Musicals)), count], [playlist(conservative=true, Musicals), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(Musicals)), count], [playlist(Musicals), randomsong]) count = count + list.length(playlist.parse(Musicals)) -randomsong = random(weights=[list.length(playlist.parse(Soundtracks)), count], [playlist(conservative=true, Soundtracks), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(Soundtracks)), count], [playlist(Soundtracks), randomsong]) count = count + list.length(playlist.parse(Soundtracks)) -randomsong = random(weights=[list.length(playlist.parse(JoakimRemixes)), count], [playlist(conservative=true, JoakimRemixes), randomsong]) +randomsong = random(weights=[list.length(playlist.parse(JoakimRemixes)), count], [playlist(JoakimRemixes), randomsong]) count = count + list.length(playlist.parse(JoakimRemixes)) -#randomsong = random(weights=[list.length(playlist.parse(Halloween)), count], [playlist(conservative=true, Halloween), randomsong]) -#count = count + list.length(playlist.parse(Halloween)) +randomsong = random(weights=[list.length(playlist.parse(Halloween)), count], [playlist(Halloween), randomsong]) +count = count + list.length(playlist.parse(Halloween)) randomsong = audio_to_stereo(randomsong)