Hi Team,
I have tested this script:
out = output.icecast(%mp3(bitrate=128, samplerate=44100),
host = "localhost", port = 8000,
password = "hackme",
mount = "stream",
fallible=true)
def my_request_function() =
# Get the first line of my external process
result =
list.hd(
get_process_lines("php-cgi -q /path/to/request.php"))
# Create and return a request using this result
request.create(result)
end
def start_stream(url, title, artist, time) =
server.execute("live.url #{url}")
server.execute("live.start")
rewrite_metadata([("title",#{title}), ("artist",#{artist})],http_src)
add_timeout(fast=false,#{time},server.execute("live.stop"))
end<-This ligne failed
# Create the source
http_src = input.http(id="live", buffer=1., max=2.,
"http://default.url/stream.mp3")
automatic = strip_blank(request.dynamic(my_request_function))
source=fallback(track_sensitive=true,[http_src, automatic])
output=out(source)
server.register(namespace="live",
usage="start_stream<URL> <TITLE> <ARTIST> <TIME>",
description="Start Live.",
"start_stream",start_stream)
But it's does'nt work: i have a parse error!(??)
Cheers
Antoine
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users