Hi Francisco, very thanks. I will try to integrate the scripts at the next debs.
Georg Am Donnerstag, den 30.08.2007, 10:57 +0200 schrieb Francisco Eduardo Álvarez Solano: > I'm configuring a fresh install of Freevo based on Ubuntu Feisty Fawn, > server. After installing Freevo form apt sources, I've disabled the > standard init scripts that come with the distribution and I've written > an upstart script instead. > > You should remove the freevo service, and add the file > > /etc/event.d/freevo: > > ########################### > start on runlevel > 2 > > > stop on runlevel > 0 > stop on runlevel > 1 > stop on runlevel > 6 > > > respawn # This ensures that freevo will be restarted if it crashed > exec freevo -fs > ############################# > > If you don't want freevo to run as root, you can write a script > instead of the 'exec' stanza: > script > > > LANG=es_ES.UTF-8 > USER=casa > > > HOME=/casa/ > > FREEVO=/usr/bin/freevo > export LANG USER HOME > FREEVO > > > exec sudo -H -u casa freevo > -fs > end script > > > Now it is very easy to add other scripts to launch the record server > or the encoding server: > > /etc/event.d/recordserver: > > ##################################### > start on runlevel 2 > > stop on runlevel 0 > stop on runlevel 1 > stop on runlevel 6 > > respawn > exec freevo recordserver start > ###################################### > > > You can even start services before or after another one. Here is my > script to download the epg data from internet: > > /etc/event.d/epg: > > ########################################## > start on started freevo # Or 'start on started recordserver' > > > stop on runlevel > 0 > stop on runlevel > 1 > stop on runlevel > 6 > > > exec /etc/freevo/scripts/epg.sh > ############################################# > > > And here it is /etc/freevo/scripts/epg.sh: > > ######################################### > #!/bin/sh > > > > DIR="/var/cache/freevo/" > > GUIDE="$DIR/TV.xml" > > TMP="$DIR/tmp" > > > > touch -t `date +%m%d`0000 > $TMP > if [ $GUIDE -ot $TMP ] # If TV.xml is outdated > then > > while [ 1 ] # we wait till internet is available > > do > ping -c 1 www.elpais.es && > break > > done > freevo tv_grab # and download it > fi > > rm $TMP > ############################################ > > > Hope this will be of interest. > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ Freevo-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/freevo-users
signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil
------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________ Freevo-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/freevo-users
