Hej I have made a install script for the Photo Gallery 1.5.3
here is the script:
#!/bin/sh
clear
echo ""
echo "================================================================================="
echo "= gallery-install_1.5.3.sh "
echo "= "
echo "= It installs libtiff, netpgm and jhead as well as Gallery "
echo "= "
echo "= ------------------------------------------------------------------------------ "
echo "= This Gallery installation script is build on script from by Jesper Knudsen at "
echo "= http://sme.swerts-knudsen.dk "
echo "= "
echo "= Upgrade made by Svenn-Erik Krengelund Thomsen at "
echo "= www ......: http://sekt.dk "
echo "= e-mail ...: sekt@sekt.dk "
echo "= skype-me .: svenn-erik "
echo "= "
echo "= ------------------------------------------------------------------------------ "
echo "= Revision History: "
echo "= "
echo "= May 28, 2006: Updated to gallery-1.5.3.tar.gz "
echo "= and jhead-2.6-1.rh7.rf.i386.rpm "
echo "= "
echo "= May 29, 2006: Upgrade to install more than one Gallery in same IBay "
echo "= Syntax to use is: "
echo "= sh gallery-install_1.5.3.sh Directory Ibay "
echo "= Directory defaults to : gallery "
echo "= IBay defaults to .....: Primary "
echo "= "
echo "================================================================================="
echo "= "
echo "= No express or implied warranties are provided and its usage is at your own "
echo "= risk. "
echo "= "
echo "= If you feel confortable with the above then press <Enter> if not pres "
echo "= <Ctrl>+C to abort the installation script. "
echo "= "
echo "================================================================================="
read x
cls
if [ $1 ]
then
echo "Using install directory as specified on command line = \"$1\""
MyDir=$1
else
echo "No Install directory specified using default \"gallery\""
MyDir="gallery"
fi
if [ $2 ]
then
echo "Using install ibay as specified on command line = \"$2\""
MyIBay=$2
else
echo "No Install ibay specified using default \"Primary\""
MyIBay="Primary"
fi
if [ -d /home/e-smith/files/ibays/$MyIBay ]
then
mkdir -p /root/plus/gallery/gallery153
cd /root/plus/gallery/gallery153
rpm -qa > rpmlist
echo ""
echo "================================================================================="
echo "= First Download all the required RPMs "
echo "================================================================================="
echo ""
wget -nc ftp://mirror.switch.ch/mirror/fedoralegacy/redhat/7.3/os/i386/libtiff-3.5.7-2.i386.rpm
wget -nc ftp://mirror.switch.ch/mirror/fedoralegacy/redhat/7.3/updates/i386/netpbm-9.24-9.73.4.legacy.i386.rpm
wget -nc ftp://mirror.switch.ch/mirror/fedoralegacy/redhat/7.3/updates/i386/netpbm-progs-9.24-9.73.4.legacy.i386.rpm
wget -nc http://kent.dl.sourceforge.net/sourceforge/gallery/gallery-1.5.3.tar.gz
wget -nc ftp://ftp.freshrpms.net/pub/dag/redhat/7.3/en/i386/dag/RPMS/jhead-2.6-1.rh7.rf.i386.rpm
echo ""
echo "================================================================================="
echo "= Install all the required RPMs "
echo "================================================================================="
echo ""
if [ grep -c libtiff-3 rpmlist -eq 0 ]
then
rpm -Uvh libtiff-3.5.7-2.i386.rpm
fi
if [ grep -c netpbm-9 rpmlist -eq 0 ]
then
rpm -Uvh netpbm-9.24-9.73.4.legacy.i386.rpm
fi
if [ grep -c netpbm-progs-9 rpmlist -eq 0 ]
then
rpm -Uvh netpbm-progs-9.24-9.73.4.legacy.i386.rpm
fi
if [ grep -c jhead-2 rpmlist -eq 0 ]
then
rpm -Uvh jhead-2.6-1.rh7.rf.i386.rpm
fi
echo ""
echo "================================================================================="
echo "= Now gallery itself "
echo "================================================================================="
echo "= "
echo "= Gallery created at: "
echo "= /home/e-smith/files/ibays/$MyIBay/html/$MyDir "
echo "================================================================================="
echo ""
mkdir -p /home/e-smith/files/ibays/$MyIBay/html/$MyDir
tar xzf gallery-1.5.3.tar.gz
cd gallery
mv * /home/e-smith/files/ibays/$MyIBay/html/$MyDir
mkdir -p /home/e-smith/files/ibays/$MyIBay/html/$MyDir/albums
mkdir -p /home/e-smith/files/ibays/$MyIBay/html/$MyDir/temp
chmod -R 777 /home/e-smith/files/ibays/$MyIBay/html/$MyDir/albums
chmod -R 777 /home/e-smith/files/ibays/$MyIBay/html/$MyDir/temp
cd ..
rmdir gallery
rm -rf rpmlist
echo ""
echo "================================================================================="
echo "= Allow gallery to use jhead from an iBay "
echo "= --------------------------------------- "
echo "= /sbin/e-smith/signal-event ibay-modify $MyIBay "
echo "= Please wait! "
echo "================================================================================="
echo ""
/sbin/e-smith/db accounts setprop $MyIBay PHPBaseDir /home/e-smith/files/ibays/$MyIBay/:/usr/bin
/sbin/e-smith/signal-event ibay-modify $MyIBay
echo ""
echo "================================================================================="
echo "= Enable configuration "
echo "================================================================================="
cd /home/e-smith/files/ibays/$MyIBay/html/$MyDir
sh configure.sh
clear
echo ""
echo "=================================================================================="
echo "= 1. Now point your web browser to http://yourhost.yourdomain/gallery/setup. "
echo "= Go ahead and click the "Configure Gallery" button at the bottom of this "
echo "= page. "
echo "= "
echo "= 2. On the next page, there are a few items you'll need to enter. "
echo "= First is the admin password; you may set this to anything you like. "
echo "= "
echo "= 3. Other things that need setting: "
echo "= PNM to JPEG converter : ppmtojpeg "
echo "= Album directory ......: /home/e-smith/files/ibays/$MyIBay/html/$MyDir/albums "
echo "= Albums URL ...........: http://yourhost.yourdomain/$MyIBay/$MyDir/albums "
echo "= Temporary directory ..: /home/e-smith/files/ibays/$MyIBay/html/$MyDir/temp "
echo "= "
echo "= 4. The rest of the defaults should be fine. Proceed to the next screen when "
echo "= you can either configure or press <Save Settings>. At this screen, if "
echo "= there are any errors, they will appear in red text. If there's no red, "
echo "= scroll down to the bottom of the page and click on "Save Config". At this "
echo "= point, your configuration is complete. "
echo "= "
echo "= 5. Return to the console (or telnet/ssh app) and do "
echo "= [root@e-smith $MyDir]# sh secure.sh "
echo "= "
echo "= 6. You're done! Point your browser to http://yourhost.yourdomain/gallery, log "
echo "= in as "admin" with the admin password you chose previously, and create some "
echo "= galleries. Upload some pictures. "
echo "= "
echo "= You can find some of my gallery at .: "
echo "= http://foto.sekt.dk "
echo "= http://magasinfestival.dk/index.php?TheAction=Galleri "
echo "= "
echo "= 7. Enjoy! "
echo "=================================================================================="
else
clear
echo ""
echo "================================================================================="
echo "= Sorry: "
echo "= Ibay called \"$MyIBay\" does not exist - Installation terminated! "
echo "= "
echo "= The default IBay is "Primary", but any ibay can be used "
echo "= The default Directory is "gallery", but any name can be used "
echo "= "
echo "= ------------------------------------------------------------------------------ "
echo "= Please use the Server-Manager and create one: "
echo "= http://yourhost.yourdomain/server-manager "
echo "= "
echo "= Information bay name ..........: $MyIBay "
echo "= Description ...................: Networked Picture Gallery "
echo "= Group .........................: Admin "
echo "= User access ...................: Write=group, Read=everyone "
echo "= Public access .................: As you like it "
echo "= Execution of dynamic content ..: enabled "
echo "= "
echo "================================================================================="
fi
Have fun.
sekt.