0

I am working on a system that has a staging environment and a live environment. We have a problem with images not getting pushed to live and I have found the following script that handles it:

#!/bin/sh
#
# Script to handle copy of NR images to prod
#

#create working space
if [ -d /export/home/webuser/uploads/nrimg ]
then
rm -rf /export/home/webuser/uploads/nrimg
fi

mkdir /export/home/webuser/uploads/nrimg

#cd /export/home/webuser/uploads/nrimg

#create image tar

cd /export/home/webuser/www/EE/public_html/lib-ui/img
zipfile="../../../../../../uploads/nrimg/nr.tar"
echo  "Creating $zipfile..."
tar cf $zipfile news 


cd /export/home/www/bin

perl promoteArchive.pl /export/home/webuser/uploads/nrimg/nr.tar /export/home/webuser/www/uk/public_html/lib-ui/img
perl promoteArchive.pl /export/home/webuser/uploads/nrimg/nr.tar /export/home/webuser/www/bac_co_uk/public_html/lib-ui/img
perl promoteArchive.pl /export/home/webuser/uploads/nrimg/nr.tar /export/home/webuser/www/ireland/public_html/lib-ui/img

Am I right in thinking that in order for the bottom three lines to work there should be a file called promoteArchive.pl in /export/home/webuser/uploads/nrimg

I can't find one and think this might be the problem but I don't really know

geoffs3310
  • 113
  • 2

1 Answers1

3

In this case perl is trying to run a script called promoteArchive.pl in the /export/home/www/bin directory. The rest of the command is parameters that promoteArchive.pl is expecting which appear to be an archive and a destination directory.

user9517
  • 115,471
  • 20
  • 215
  • 297