I'm using liquidsoap as source client for icecast. I try running http source from pls file, but not working. When I use input.http() function, everything is ok. What to do to read the http source from the pls file ? What's wrong with my example? This is my streaming script:
classic_mp3_high_mount = "classic_aac_low"
classic_pls = "./pls/classic.pls"
set("server.telnet",true)
set("log.file.path","./log/streaming.log")
classic_request=request.queue(id="classic_queue")
classic_pls = playlist.safe(mode="normal", classic_pls);
jingles_pls = playlist.safe(mode="random", jingles_pls);
classic_stream = fallback([classic_request, classic_pls])
aac_low_out = output.icecast(%mp3(bitrate=320),
host=host,
mount=classic_mp3_high_mount,
port=port,
password=password,
classic_stream)
And this is log with error:
2018/05/13 16:31:30 [classic(dot)pls:3] Loading playlist...
2018/05/13 16:31:30 [classic(dot)pls:3] No mime type specified, trying autodetection.
2018/05/13 16:31:30 [classic(dot)pls:3] Playlist treated as format audio/x-scpls
2018/05/13 16:31:30 [clock.wallclock_main:2] Error when starting classic_aac_low: File "sources/playlist.ml", line 245, characters 8-14: Assertion failed!
2018/05/13 16:31:30 [clock.wallclock_main:3] Raised at file "sources/playlist.ml", line 245, characters 8-64
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "sources/playlist.ml", line 492, characters 4-32
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "sources/playlist.ml", line 475, characters 4-23
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "sources/playlist.ml", line 503, characters 4-31
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "operators/switch.ml", line 105, characters 9-45
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "list.ml", line 73, characters 12-15
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "list.ml", line 73, characters 12-15
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "operators/switch.ml", line 105, characters 9-45
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "list.ml", line 73, characters 12-15
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "list.ml", line 73, characters 12-15
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "list.ml", line 73, characters 12-15
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "outputs/output.ml", line 130, characters 4-51
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "source.ml", line 388, characters 6-29
2018/05/13 16:31:30 [clock.wallclock_main:3] Called from file "clock.ml", line 221, characters 15-40
2018/05/13 16:31:30 [classic_aac_low:1] Got ill-balanced activations (from classic_aac_low)!
2018/05/13 16:31:30 [clock:2] Error when leaving output classic_aac_low: File "source.ml", line 414, characters 10-16: Assertion failed!
2018/05/13 16:31:30 [clock:3] Raised at file "source.ml", line 414, characters 10-22
2018/05/13 16:31:30 [clock:3] Called from file "source.ml", line 421, characters 30-58
2018/05/13 16:31:30 [clock:3] Called from file "clock.ml", line 79, characters 6-25
2018/05/13 16:31:30 [main:3] Shutdown started!
2018/05/13 16:31:30 [main:3] Waiting for threads to terminate...
2018/05/13 16:31:30 [main:3] Threads terminated.
2018/05/13 16:31:30 [threads:3] Shutting down scheduler...
2018/05/13 16:31:30 [threads:3] Scheduler shut down.
2018/05/13 16:31:30 [server:3] Closing socket.
2018/05/13 16:31:30 [main:3] Cleaning downloaded files...
2018/05/13 16:31:30 [main:3] Freeing memory...
2018/05/13 16:31:30 >>> LOG END
pls file:
[playlist]
File2=http://media.friskyradio.com.s3.amazonaws.com/2dc/2DCAnni_1Yr_Rob_Keith_003.mp3
NumberOfEntries=4
when I use local path instead of http url everything is ok.
I'm going to take the liberty to reframe the question:
How to use Amazon S3 as file storage and access it from Liquidsoap?
As luck has it, I've recently answered a very similar question:
Icecast server with AWS S3 files
(tl;dr - mount the bucket as a regular directory)