r22187: Test kerberos logins in the smbclient blackbox tests, including with a
[Samba.git] / source / script / installwebapps.sh
blob25a43dba2472c4498794164fcbf4391a9a7d672f
1 #!/bin/sh
3 WEBAPPSDIR=$1
4 SRCDIR=$2
6 echo Installing web application files in $WEBAPPSDIR
8 cd $SRCDIR/../webapps/swat || exit 1
10 # building the web application framework is now done by autogen.sh
11 #make build || exit 1
13 mkdir -p $WEBAPPSDIR || exit 1
15 installdir() {
16 for f in $*; do
17 dname=`dirname $f`
18 echo "Installing $f in $dname"
19 test -d $WEBAPPSDIR/$dname || mkdir -p $WEBAPPSDIR/$dname || exit 1
20 cp $f $WEBAPPSDIR/$dname/ || exit 1
21 chmod 0644 $WEBAPPSDIR/$f || exit 1
22 done
25 # install our web application
26 cd build || exit 1
27 installdir `find . -type f -print`
29 # install files from the 'scripting', 'style' and 'images' directories
30 cd ../.. || exit 1
31 installdir `find scripting -name '*.js'`
32 installdir `find scripting -name '*.esp'`
33 installdir `find style -name '*.css'`
34 installdir `find images -name '*.png'`
35 installdir `find images -name '*.gif'`
36 installdir `find images -name '*.ico'`
38 # install the old installation scripts, since there's no replacement yet
39 installdir `find install -name '*.esp'`
41 # install top-level scripts
42 installdir index.esp login.esp logout.esp menu.js
44 cat << EOF
45 ======================================================================
46 The web application files have been installed.
47 ======================================================================
48 EOF
50 exit 0