added files needed by the installation process
This commit is contained in:
parent
75c97ccb8e
commit
048a69cfec
4 changed files with 273 additions and 0 deletions
99
livesupport/products/scheduler/bin/scheduler.sh
Executable file
99
livesupport/products/scheduler/bin/scheduler.sh
Executable file
|
@ -0,0 +1,99 @@
|
|||
#!/bin/sh
|
||||
#-------------------------------------------------------------------------------# Copyright (c) 2004 Media Development Loan Fund
|
||||
#
|
||||
# This file is part of the LiveSupport project.
|
||||
# http://livesupport.campware.org/
|
||||
# To report bugs, send an e-mail to bugs@campware.org
|
||||
#
|
||||
# LiveSupport is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# LiveSupport is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with LiveSupport; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
#
|
||||
#
|
||||
# Author : $Author: maroy $
|
||||
# Version : $Revision: 1.1 $
|
||||
# Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/products/scheduler/bin/scheduler.sh,v $
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# System V runlevel style invoke script for the LiveSupport Scheduler
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Determine directories, files
|
||||
#-------------------------------------------------------------------------------
|
||||
reldir=`dirname $0`/..
|
||||
basedir=`cd $reldir; pwd;`
|
||||
bindir=$basedir/bin
|
||||
etcdir=$basedir/etc
|
||||
libdir=$basedir/lib
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Set up the environment
|
||||
#-------------------------------------------------------------------------------
|
||||
export LD_LIBRARY_PATH=$libdir:$LD_LIBRARY_PATH
|
||||
scheduler_exe=$bindir/scheduler
|
||||
config_file=$etcdir/scheduler.xml
|
||||
|
||||
mode=$1
|
||||
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Do what the user asks us to do
|
||||
#-------------------------------------------------------------------------------
|
||||
case "$mode" in
|
||||
'start')
|
||||
echo "Starting the LiveSupport scheduler..."
|
||||
$scheduler_exe -c $config_file start
|
||||
sleep 2
|
||||
;;
|
||||
|
||||
'stop')
|
||||
echo "Stopping the LiveSupport scheduler..."
|
||||
$scheduler_exe -c $config_file stop
|
||||
sleep 2
|
||||
;;
|
||||
|
||||
'status')
|
||||
echo "Checking LiveSupport scheduler status..."
|
||||
$scheduler_exe -c $config_file status
|
||||
;;
|
||||
|
||||
'install')
|
||||
echo "Installing LiveSupport scheduler database tables..."
|
||||
$scheduler_exe -c $config_file install
|
||||
;;
|
||||
|
||||
'uninstall')
|
||||
echo "Uninstalling LiveSupport scheduler database tables..."
|
||||
$scheduler_exe -c $config_file uninstall
|
||||
;;
|
||||
|
||||
'kill')
|
||||
echo "Killing all LiveSupport scheduler processes..."
|
||||
killall scheduler
|
||||
sleep 2
|
||||
killall -9 scheduler
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "LiveSupport scheduler System V runlevel init script."
|
||||
echo ""
|
||||
echo "Usage:"
|
||||
echo " $0 start|stop|status|install|uninstall|kill"
|
||||
echo ""
|
||||
|
||||
esac
|
||||
|
18
livesupport/products/scheduler/etc/odbc_template
Normal file
18
livesupport/products/scheduler/etc/odbc_template
Normal file
|
@ -0,0 +1,18 @@
|
|||
[ls_database]
|
||||
Description = the LiveSupport database at PostgreSQL
|
||||
Driver = PostgreSQL
|
||||
Trace = No
|
||||
TraceFile = /tmp/sql.log
|
||||
Database = ls_database
|
||||
Servername = ls_dbserver
|
||||
Username =
|
||||
Password =
|
||||
Port = 5432
|
||||
Protocol = 6.4
|
||||
ReadOnly = No
|
||||
RowVersioning = No
|
||||
ShowSystemTables = No
|
||||
ShowOidColumn = No
|
||||
FakeOidIndex = No
|
||||
ConnSettings =
|
||||
|
5
livesupport/products/scheduler/etc/odbcinst_template
Normal file
5
livesupport/products/scheduler/etc/odbcinst_template
Normal file
|
@ -0,0 +1,5 @@
|
|||
[PostgreSQL]
|
||||
Description = PostgreSQL driver
|
||||
Driver = /usr/lib/libodbcpsql.so
|
||||
Setup = /usr/lib/libodbcpsqlS.so
|
||||
|
151
livesupport/products/scheduler/etc/scheduler.xml.template
Normal file
151
livesupport/products/scheduler/etc/scheduler.xml.template
Normal file
|
@ -0,0 +1,151 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE scheduler [
|
||||
|
||||
<!ELEMENT scheduler (user,
|
||||
connectionManagerFactory,
|
||||
authenticationClientFactory,
|
||||
storageClientFactory,
|
||||
scheduleFactory,
|
||||
playLogFactory,
|
||||
audioPlayer,
|
||||
xmlRpcDaemon,
|
||||
tagConversionTable) >
|
||||
|
||||
<!ELEMENT connectionManagerFactory (simpleConnectionManager) >
|
||||
|
||||
<!ELEMENT simpleConnectionManager EMPTY >
|
||||
<!ATTLIST simpleConnectionManager dsn CDATA #REQUIRED >
|
||||
<!ATTLIST simpleConnectionManager userName CDATA #REQUIRED >
|
||||
<!ATTLIST simpleConnectionManager password CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT authenticationClientFactory (testAuthentication|
|
||||
webAuthentication)>
|
||||
|
||||
<!ELEMENT testAuthentication (user) >
|
||||
|
||||
<!ELEMENT user EMPTY >
|
||||
<!ATTLIST user login CDATA #REQUIRED >
|
||||
<!ATTLIST user password CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT webAuthentication (location) >
|
||||
|
||||
<!ELEMENT location EMPTY >
|
||||
<!ATTLIST location server CDATA #REQUIRED >
|
||||
<!ATTLIST location port NMTOKEN #REQUIRED >
|
||||
<!ATTLIST location path CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT storageClientFactory (testStorage|webStorage) >
|
||||
|
||||
<!ELEMENT testStorage (playlist*, audioClip*) >
|
||||
<!ATTLIST testStorage tempFiles CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT webStorage (location) >
|
||||
<!ATTLIST webStorage tempFiles CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT playlist (playlistElement*) >
|
||||
<!ATTLIST playlist id NMTOKEN #REQUIRED >
|
||||
<!ATTLIST playlist playlength NMTOKEN #REQUIRED >
|
||||
|
||||
<!ELEMENT playlistElement ((audioClip|playlist), fadeInfo?) >
|
||||
<!ATTLIST playlistElement id NMTOKEN #REQUIRED >
|
||||
<!ATTLIST playlistElement relativeOffset NMTOKEN #REQUIRED >
|
||||
|
||||
<!ELEMENT audioClip EMPTY >
|
||||
<!ATTLIST audioClip id NMTOKEN #REQUIRED >
|
||||
<!ATTLIST audioClip playlength NMTOKEN #REQUIRED >
|
||||
<!ATTLIST audioClip title CDATA #REQUIRED >
|
||||
<!ATTLIST audioClip uri CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT fadeInfo EMPTY >
|
||||
<!ATTLIST fadeInfo id NMTOKEN #REQUIRED >
|
||||
<!ATTLIST fadeInfo fadeIn NMTOKEN #REQUIRED >
|
||||
<!ATTLIST fadeInfo fadeOut NMTOKEN #REQUIRED >
|
||||
|
||||
<!ELEMENT scheduleFactory (postgresqlSchedule) >
|
||||
<!ELEMENT postgresqlSchedule EMPTY >
|
||||
|
||||
<!ELEMENT playLogFactory (postgresqlPlayLog) >
|
||||
<!ELEMENT postgresqlPlayLog EMPTY >
|
||||
|
||||
<!ELEMENT audioPlayer (helixPlayer) >
|
||||
|
||||
<!ELEMENT helixPlayer EMPTY >
|
||||
<!ATTLIST helixPlayer dllPath CDATA #REQUIRED >
|
||||
|
||||
<!ELEMENT xmlRpcDaemon EMPTY >
|
||||
<!ATTLIST xmlRpcDaemon xmlRpcHost CDATA #REQUIRED >
|
||||
<!ATTLIST xmlRpcDaemon xmlRpcPort NMTOKEN #REQUIRED >
|
||||
<!ATTLIST xmlRpcDaemon pidFileName CDATA #REQUIRED >
|
||||
<!ATTLIST xmlRpcDaemon background (true|false) "true" >
|
||||
|
||||
<!ELEMENT tagConversionTable (tag*) >
|
||||
<!ELEMENT tag (id3+, dc) >
|
||||
<!ELEMENT id3 (#PCDATA) >
|
||||
<!ELEMENT dc (#PCDATA) >
|
||||
|
||||
]>
|
||||
<scheduler>
|
||||
<user login="root" password="q" />
|
||||
|
||||
<connectionManagerFactory>
|
||||
<simpleConnectionManager dsn = "ls_database"
|
||||
userName = "ls_dbuser"
|
||||
password = "ls_dbpassword"
|
||||
/>
|
||||
</connectionManagerFactory>
|
||||
|
||||
<authenticationClientFactory>
|
||||
<webAuthentication>
|
||||
<location server="ls_php_host" port="ls_php_port"
|
||||
path="ls_php_urlPrefix/ls_alib_xmlRpcPrefix"/>
|
||||
</webAuthentication>
|
||||
</authenticationClientFactory>
|
||||
|
||||
<storageClientFactory>
|
||||
<webStorage tempFiles="file:///ls_install_dir/tmp/webStorageClient" >
|
||||
<location server="ls_php_host" port="ls_php_port"
|
||||
path="ls_php_urlPrefix/ls_storage_xmlRpcPrefix"/>
|
||||
</webStorage>
|
||||
</storageClientFactory>
|
||||
|
||||
<scheduleFactory>
|
||||
<postgresqlSchedule/>
|
||||
</scheduleFactory>
|
||||
|
||||
<playLogFactory>
|
||||
<postgresqlPlayLog/>
|
||||
</playLogFactory>
|
||||
|
||||
<audioPlayer>
|
||||
<helixPlayer dllPath = "ls_install_dir/usr/lib/helix"/>
|
||||
</audioPlayer>
|
||||
|
||||
<xmlRpcDaemon xmlRpcHost = "ls_scheduler_host"
|
||||
xmlRpcPort = "ls_scheduler_port"
|
||||
pidFileName = "ls_install_dir/tmp/scheduler.pid"
|
||||
/>
|
||||
|
||||
<tagConversionTable>
|
||||
<tag>
|
||||
<id3>Title</id3>
|
||||
<id3>TIT2</id3>
|
||||
<dc>dc:title</dc>
|
||||
</tag>
|
||||
<tag>
|
||||
<id3>TPE1</id3>
|
||||
<id3>Artist</id3>
|
||||
<dc>dc:creator</dc>
|
||||
</tag>
|
||||
<tag>
|
||||
<id3>Length</id3>
|
||||
<id3>TLEN</id3>
|
||||
<dc>dcterms:extent</dc>
|
||||
</tag>
|
||||
<tag>
|
||||
<!-- beats per minute -->
|
||||
<id3>TBPM</id3>
|
||||
<dc>ourdcextension:bpm</dc>
|
||||
</tag>
|
||||
</tagConversionTable>
|
||||
</scheduler>
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue