The script has a shebang and works well with php5-cli :) Add 
"/usr/bin/php" or "php" doesn't change anything..
Also, the script return a good uri:
[oxyra...@freedom:~/liquidsoap/test]$./oxycast.php
/home/oxyradio/musique/pop/Cof Cof - Dirty Tricks.mp3

And it works by using liquidsoap 
'output.dummy(fallible=true,request.dynamic({request.create(get_process_output("/home/oxyradio/liquidsoap/test/oxycast.php"))}))'
 
but does not in my script file..

Gabriel Afana wrote:
> Sorry if I may not be thinking correctly here, but in my 
> implementation, It seems get_process_output acts as a system command 
> interface.  That being said, I include "/usr/bin/php" because at least 
> on my box, I can't just enter:
>
> root> /var/web/website/something.php
>
> It wont do anything.  I call PHP like
>
> root> /usr/bin/php /var/web/website/something.php
>
> Also, have you tested your PHP for sure?  I've noticed there is an 
> apache version of PHP and a command version of PHP.  They are both the 
> same, but have different environmental variables set which can cause 
> it to work perfect if you go to www.mysite.com/test.php but if you 
> run:  /usr/bin/php /var/web/mysite/test.php it will fail
>
> Try running the script directly in the console and see if it returns 
> the URI for a track. If not, you need to investigate getting the 
> script working in the CLI
>
> ----- Original Message -----
> From: Solvik Blum <[email protected]>
> To: [email protected]
> Sent: Tue, 30 Jun 2009 23:14:09 +0200
> Subject: Re: [Savonet-users] fail with request.dynamic
>
> >Thanks for your answer :)
> >
> >And yes i'm trying to enjoy my holidays... before results o/
> >
> >For my problem, here are the logs: http://solvik.pastebin.com/m31b9f3e5
> >
> >For your small test, I needed to do a chmod a+x on the file, but it
> >worked. Also, according to man, the -R option doesn't exist.
> >
> >[oxyra...@freedom:~]$liquidsoap
> >'output.dummy(fallible=true,request.dynamic({request.create(get_process_output("test
> > 
>
> >-f /tmp/foo && ls /home/oxyradio/musique/jazz/ | sort -r | head -n
> >1"))}))'2009/06/30 22:54:36 >>> LOG START
> >2009/06/30 22:54:36 [protocols.external:3] Didn't find "ufetch"
> >2009/06/30 22:54:36 [protocols.external:3] Found "/usr/bin/wget"
> >2009/06/30 22:54:36 [main:3] Liquidsoap 0.9.1+svn 
> (trunk/liquids...@rev6682)
> >2009/06/30 22:54:36 [lang:3] flac binary not found: flac decoder 
> disabled.
> >2009/06/30 22:54:36 [lang:3] metaflac binary not found: flac metadata
> >resolver disabled.
> >2009/06/30 22:54:36 [threads:3] Created thread "generic queue #1".
> >2009/06/30 22:54:36 [threads:3] Created thread "root" (1 total).
> >2009/06/30 22:54:36 [root:3] Waking up active nodes...
> >2009/06/30 22:54:36 [root:3] Broadcast starts up!
> >
> >
> >2009/06/30 22:54:41 [main:3] Shutdown started!
> >2009/06/30 22:54:41 [main:3] Waiting for threads to terminate...
> >2009/06/30 22:54:41 [root:3] Shutting down sources...
> >2009/06/30 22:54:41 [threads:3] Thread "root" exited (0 remaining).
> >2009/06/30 22:54:41 [main:3] Cleaning downloaded files...
> >2009/06/30 22:54:41 >>> LOG END
> >
> >By testing that on my script with: liquidsoap
> >'output.dummy(fallible=true,request.dynamic({request.create(get_process_output("/home/oxyradio/liquidsoap/test/oxycast.php"))}))',
> > 
>
> >it worked.. but still doesn't work with my script by using dole_fade and
> >skip_blank, and even by comment them..
> >
> >Don't understand where can be the problem..
> >
> >
> >David Baelde wrote:
> >> Hi Solvik,
> >>
> >> Enjoying your holidays ? :p
> >>
> >> I don't have any idea of what might be wrong with your script. As
> >> usual, I recommend trying to trace more precisely what's going on, by
> >> adding logging and tracing alive and dead requests from the server.
> >> But I also did my own experiment to check that something wasn't
> >> obviously broken. Maybe you can check if it runs fine for you too.
> >>
> >> $ liquidsoap 
> 'output.dummy(fallible=true,request.dynamic({request.create(get_process_output("test
> >> -f /tmp/foo && ls ~/media/audio/jazz/*mp3 | sort -R | head -n 1"))}))'
> >>
> >> First, it's the latest SVN. At least you need a quite recent one to
> >> get the fallible dummy output.
> >>
> >> So it's just a dynamic request queue and an output. The script called
> >> is a simple shell expression:
> >> test -f /tmp/foo && ls
> | sort -R | head -n 1
> >>
> >> The second part is just for picking a random file. The first part is
> >> for making the command fail at first (I wanted to check that the queue
> >> runs even if it's not fed initially). The protocol for starting the
> >> feeding is to "touch /tmp/foo" of course. Liquidsoap behaved as
> >> expected on this example.
> >>
> >> HTH
> >>
> >
> >------------------------------------------------------------------------------
> >_______________________________________________
> >Savonet-users mailing list
> >[email protected]
> >https://lists.sourceforge.net/lists/listinfo/savonet-users
>

------------------------------------------------------------------------------
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to