source: trunk/gsdl/Install.sh@ 2820

Last change on this file since 2820 was 2820, checked in by sjboddie, 23 years ago

Shifted all the English text from the Unix install script into local
variables (to allow easy extraction for translation)

  • Property svn:executable set to *
  • Property svn:mime-type set to application/octet-stream
File size: 34.6 KB
Line 
1#!/bin/sh
2
3## Install.sh -- Install Greenstone
4
5cmd_cp="cp"
6cmd_cpr="cp -r"
7cmd_chmod="chmod"
8cmd_mkdir="mkdir -p"
9cmd_ln="ln -s"
10cmd_mv="mv"
11cmd_rm="rm -i"
12cmd_rmr="rm -r"
13
14thisdir=`pwd`
15cd ..
16cd_dir=`pwd`
17cd "$thisdir"
18
19itext0="Greenstone was not installed"
20
21itext1="Install.sh must be run from the directory in which it resides"
22
23itext2="ERROR: Could not locate "
24
25itext3="This script will install Greenstone on your system. You may want
26to skim through the Install.pdf document that resides in the docs
27directory on this cd-rom before continuing with the installation.
28
29Note that when prompted for input, hitting \"enter\" will select
30the default (given in square brackets [] at the end of each question).
31If you're unsure which option to select, use the default.
32
33Note also that Install.sh prints out information on any commands
34it runs on your system in the form \"--> Install.sh: [command]\".
35
36It is assumed throughout this installation procedure that you
37have a webserver installed on your system.
38
39For later reference the output of this install script will be
40recorded in a file called INSTALL_RECORD in the directory into
41which you choose to install Greenstone.
42
43Continue? [y]"
44
45itext4="
46Which directory should Greenstone be installed to?
47Make sure that this directory is on a partition with sufficient
48free disk space for the installation options you intend selecting."
49
50itext5="
51 * A linux binary installation requires approximately
52 40Mb."
53
54itext6="
55 * Compiling Greenstone from source code requires
56 approximately 155Mb.
57 * Optional Greenstone demonstration collections may use up
58 to a further 200Mb (you'll be told the size of each individual
59 collection before you install it).
60 * Online documentation requires a further 5Mb.
61 * Enabling Greenstone's \"CD exporting\" function requires a
62 further 24Mb.
63Enter directory to install Greenstone into. A gsdl directory
64will be created in this directory. [${gsdlhome}]"
65
66itext7="
67Warning: The ${gsdlhome} directory does not exist.
68Create it? [y]"
69
70itext8="ERROR: failed to create $gsdlhome directory"
71
72itext9="
73If this installation fails or is cancelled, run the uninstall
74script (${gsdlhome}/Uninstall.sh) to clean up the partial
75installation.
76Continue? [y]"
77
78itext10="
79Installing Greenstone directory structure to ${gsdlhome}"
80
81itext11="
82Would you like to install the Greenstone documentation to your
83hard drive? The docs will use about 5Mb of space. If you choose
84not to install them you can still access them from within the
85docs directory of the cd-rom) [y]"
86
87itext12="
88Would you like to install support for Greenstone's \"CD exporting\"
89function? This function allows you to export a Greenstone collection
90in a form suitable for writing to a self-installing Windows cd-rom.
91This package will use approximately 23Mb of disk space [n]"
92
93itext13="
94The Greenstone demonstration collection has been installed. Would you
95like to install any other collections from the installation cd-rom? [y]
96(note that only the built indexes will be installed for these
97collections - if you require the original source documents you may
98manually copy them from the \"collect\" directory of the cd-rom)"
99
100itext14="
101Install the Greenstone mailing list archive (gsarch) - 3Mb? [y]"
102
103itext15="
104Install the MSWord/PDF/RTF/Postscript demonstration collection (wordpdf) - 4Mb? [y]"
105
106itext16="
107Install the Chinese demonstration collection (chinese) - 1Mb? [y]"
108
109itext17="
110Install the Humanity Development Library subset (hdlsub) - 150 Mb? [y]"
111
112itext18="Setting permissions ..."
113
114itext19="
115In order for end-user collection building to be enabled the
116Greenstone cgi program must be able to write to the
117${gsdlhome}/collect and ${gsdlhome}/tmp directories.
118On most systems this means they must be globally writable.
119Make these directories globally writable? [y]"
120
121itext20="
122You may either install pre-compiled, statically linked linux [b]inaries
123(i386 only) or install and [c]ompile the Greenstone source code"
124
125itext21="Enter \"[b]\" or \"c\""
126
127itext22="Installing linux binaries"
128
129itext23="Installing source code"
130
131itext24="configuring ..."
132
133itext25="compiling ..."
134
135itext26="installing ..."
136
137itext27="ERROR: Compilation failed"
138
139itext28="
140
141Greenstone needs a valid cgi executable directory (normally called
142cgi-bin on unix systems) from which to run.
143This may be either:
144 1. The default Greenstone cgi-bin directory (${gsdlhome}/cgi-bin).
145 If you use the Greenstone default you will need to configure
146 your webserver to treat this directory as a cgi executable
147 directory. For the Apache webserver you use the ScriptAlias
148 directive to do this (details of how to configure your webserver
149 will be displayed at the end of this installation procedure)."
150
151itext29=" Note that you will probably need help from your system
152 administrator to reconfigure your webserver."
153
154itext30=" 2. An existing cgi-bin directory. Normally a cgi-bin directory
155 is created when your webserver is installed. Typically, this
156 might be /home/httpd/cgi-bin, or /usr/local/apache/cgi-bin, or
157 /var/lib/apache/cgi-bin."
158
159itext31=" Many systems also allow individual users to have their own
160 cgi-bin in /home/username/public_html/cgi-bin."
161
162itext32="Enter \"[1]\" or \"2\""
163
164itext33="
165Don't forget to configure your webserver to treat $cgi_bin
166as a cgi executable directory. Don't worry, you'll be
167reminded of this again at the end of the installation
168procedure"
169
170itext34="
171Enter existing cgi executable directory [/usr/local/apache/cgi-bin]"
172
173itext35="Warning: The ${cgi_bin} directory does not exist.
174Create it? [y]"
175
176itext36="Don't forget to configure your webserver to treat $cgi_bin
177as a cgi executable directory. Don't worry, you'll be
178reminded of this again at the end of the installation
179procedure"
180
181itext37="Run the uninstall script (${gsdlhome}/Uninstall.sh)
182to clean up the partial installation."
183
184itext38="ERROR: failed to create $cgi_bin directory"
185
186itext39="
187Unable to write to $cgi_bin directory. You will need
188to copy the contents of ${gsdlhome}/cgi-bin
189to $cgi_bin after this installation is completed.
190You'll be reminded of this again at the end of the
191installation procedure."
192
193itext40="
194Installing Greenstone cgi programs in $cgi_bin"
195
196itext41="
197Please enter the web address of the $cgi_bin
198directory. Typically this might be http://localhost/cgi-bin,
199or http://127.0.0.1/cgi-bin, or http://your-computer-name/cgi-bin,
200or http://nnn.nnn.nnn.nn/cgi-bin. [$web_cgi]"
201
202itext42="
203
204In order for Greenstone to run, the $gsdlhome
205directory and all it contains must be accessible from the web.
206To make this happen you may either:
207 1. Configure your webserver so that $gsdlhome
208 is itself accessible from the web."
209
210itext43=" 2. Provide an existing web accessible directory from which
211 a symbolic link (ln -s) will be made to $gsdlhome.
212 When your server was installed a web accessible directory
213 will have been created (the Apache webserver uses the
214 DocumentRoot directive to define this directory). Typically
215 this directory might be /home/httpd/html, or /usr/local/apache/htdocs,
216 or /var/lib/apache/htdocs."
217
218itext44=" Many systems also allow individual users to have their own
219 web accessible directory in /home/username/public_html."
220
221itext45=" Note that your web server will need to be configured to allow
222 symbolic links from within this directory. For the Apache
223 server that means this directory must be configured with
224 the SymLinksIfOwnerMatch or FollowSymLinks option (most Apache
225 installations are configured this way by default)."
226
227itext46="
228Don't forget to configure your webserver to make $gsdlhome
229accessible from the web. You'll be reminded of this again
230at the end of this installation procedure."
231
232itext47="Enter directory that is also accessible from the web [${public_html}]"
233
234itext48="
235Unable to write to $public_html directory. You will need
236to create a link called gsdl from $public_html to
237$gsdlhome after this installation is completed. You'll be
238reminded of this again at the end of the installation
239procedure."
240
241itext49="
242Enter the web address of the $public_html directory.
243This may be a relative url (e.g. \"/gsdl\") or a
244complete url (e.g. \"http://${hostname}/gsdl\") [/gsdl]"
245
246itext50="
247In order to use end-user collection building or to access certain
248parts of the administration pages you must have a password.
249A user with the username \"admin\" will be created for you with
250the password you provide (i.e. to enter any pages requiring user
251authentication enter the \"admin\" username and the password you
252set here).
253"
254
255itext51="
256
257Greenstone installation completed successfully."
258
259itext52=" * Don't forget to configure your webserver to treat
260 $cgi_bin as a cgi executable directory."
261
262itext53=" For the Apache webserver this means adding the following
263 ScriptAlias directive to your httpd.conf configuration file."
264
265itext54=" * Don't forget to move the contents of ${gsdlhome}/cgi-bin
266 to $cgi_bin
267"
268
269itext55=" * Don't forget to configure your webserver to treat
270 $gsdlhome as a web accessible directory."
271
272itext56=" For the Apache webserver this means adding the following
273 Alias directive to your httpd.conf configuration file."
274
275itext57=" * Don't forget to create a link called gsdl from $old_ph
276 to ${gsdlhome}.
277"
278
279itext58="The output of this script has been recorded for you at
280${gsdlhome}/INSTALL_RECORD.
281You may remove Greenstone from your system at any time by running
282the ${gsdlhome}/Uninstall.sh script.
283Access Greenstone by pointing a web browser at
284${web_cgi}/library
285"
286
287
288# script must be run from within cdrom/unix directory
289if [ ! -f "${thisdir}/Install.sh" ]; then
290 echo "$itext1"
291 echo "$itext0"
292 exit 1
293fi
294
295# check that various important directories are on the cd
296if [ ! -d "${cd_dir}/gsdl" ]; then
297 echo
298 echo "${itext2}${cd_dir}/gsdl"
299 echo "$itext0"
300 exit 1
301fi
302if [ ! -d "${cd_dir}/Unix/bin/linux" ]; then
303 echo
304 echo "${itext2}${cd_dir}/Unix/bin/linux"
305 echo "$itext0"
306 exit 1
307fi
308
309
310# install to /usr/local by default if user is "root", otherwise
311# default to users home directory
312gsdlos=`uname | tr A-Z a-z`
313if [ "$gsdlos" = "linux" ]; then
314 logname=`whoami`
315else
316 logname=""
317fi
318if [ "$logname" = "" ]; then
319 logname=`logname`
320fi
321gsdlhome="/home/${logname}"
322if [ "$logname" = "root" ]; then
323 gsdlhome="/usr/local"
324fi
325
326# get gsdlhome
327echo "$itext3"
328printf "%s" "> "
329read ans
330log="${log}${itext3}
331> $ans
332"
333if [ "$ans" != "" ] && [ "$ans" != "y" ]; then
334 echo "$itext0"
335 exit 0
336fi
337
338msg="$itext4"
339if [ "$gsdlos" = "linux" ]; then
340msg="${msg}$itext5"
341fi
342msg="${msg}$itext6"
343echo "$msg"
344printf "%s" "> "
345read ans
346log="${log}${msg}
347> $ans
348"
349if [ "$ans" != "" ]; then
350 gsdlhome="$ans"
351fi
352
353if [ ! -d "$gsdlhome" ]; then
354 echo "$itext7"
355 printf "%s" "> "
356 read ans
357 log="${log}${itext7}
358> $ans
359"
360 if [ "$ans" = "" ]; then
361 ans="y"
362 fi
363 if [ "$ans" = "y" ]; then
364 msg="--> Install.sh: [$cmd_mkdir \"$gsdlhome\"]"
365 echo "$msg"
366 log="${log}${msg}
367"
368 $cmd_mkdir "$gsdlhome"
369 if [ ! -d "$gsdlhome" ]; then
370 echo "$itext8"
371 echo "$itext0"
372 exit 1
373 fi
374 else
375 echo "$itext0"
376 exit 0
377 fi
378fi
379
380# from now on $gsdlhome includes the "/gsdl"
381gsdlhome="${gsdlhome}/gsdl"
382msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}\"]"
383echo "$msg"
384log="${log}${msg}
385"
386$cmd_mkdir "$gsdlhome"
387if [ ! -d "$gsdlhome" ]; then
388 echo "$itext8"
389 echo "$itext0"
390 exit 1
391fi
392# set permissions on gsdlhome directory
393msg="--> Install.sh: [$cmd_chmod u+rwx \"${gsdlhome}\"]"
394echo "$msg"
395log="${log}${msg}
396"
397$cmd_chmod u+rwx "$gsdlhome"
398
399# create initial Uninstall.sh
400cd "$gsdlhome"
401echo "#!/bin/sh" > Uninstall.sh
402echo "" >> Uninstall.sh
403echo "echo \"remove ${gsdlhome} directory? [y]\"" >> Uninstall.sh
404echo "read ans" >> Uninstall.sh
405echo "if [ \"\$ans\" = \"\" ] || [ \"\$ans\" = \"y\" ]; then" >> Uninstall.sh
406echo " $cmd_chmod -R u+rwx \"$gsdlhome\"" >> Uninstall.sh
407echo " $cmd_rmr \"$gsdlhome\"" >> Uninstall.sh
408echo "fi" >> Uninstall.sh
409$cmd_chmod u+x Uninstall.sh
410cd "$thisdir"
411
412# create initial INSTALL_RECORD
413echo "$log" >> "${gsdlhome}/INSTALL_RECORD"
414
415echo "$itext9"
416echo "$itext9" >> "${gsdlhome}/INSTALL_RECORD"
417printf "%s" "> "
418read ans
419echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
420if [ "$ans" != "" ] && [ "$ans" != "y" ]; then
421 msg="$itext0"
422 echo "$msg"
423 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
424 exit 0
425fi
426
427echo "$itext10"
428echo "$itext10" >> "${gsdlhome}/INSTALL_RECORD"
429
430# copy gsdl directory across
431msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/gsdl/\"* \"$gsdlhome\"]"
432echo "$msg"
433echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
434$cmd_cpr "${cd_dir}/gsdl/"* "$gsdlhome"
435
436# copy setup shell scripts across too
437msg="--> Install.sh: [$cmd_cp \"${cd_dir}/src/Unix/setup.\"* \"$gsdlhome\"]"
438echo "$msg"
439echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
440$cmd_cp "${cd_dir}/src/Unix/setup."* "$gsdlhome"
441
442# make sure we have a tmp directory
443if [ ! -d "$gsdlhome/tmp" ]; then
444 msg="--> Install.sh: [$cmd_mkdir \"$gsdlhome/tmp\"]"
445 echo "$msg"
446 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
447 $cmd_mkdir "${gsdlhome}/tmp"
448fi
449
450# make collect directory writable so we can install collections
451msg="--> Install.sh: [$cmd_chmod u+rwx \"$gsdlhome/collect\"]"
452echo "$msg"
453echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
454$cmd_chmod u+rwx "$gsdlhome/collect"
455
456# do we want docs directory?
457echo "$itext11"
458echo "$itext11" >> "${gsdlhome}/INSTALL_RECORD"
459printf "%s" "> "
460read ans
461echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
462if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
463 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/docs\" \"$gsdlhome\"]"
464 echo "$msg"
465 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
466 $cmd_cpr "${cd_dir}/docs" "$gsdlhome"
467fi
468
469# do we want the "CD exporting" stuff?
470echo "$itext12"
471echo "$itext12" >> "${gsdlhome}/INSTALL_RECORD"
472printf "%s" "> "
473read ans
474echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
475if [ "$ans" = "Y" ] || [ "$ans" = "y" ]; then
476 msg="--> Install.sh: [$cmd_chmod u+rw \"${gsdlhome}/bin\"]"
477 echo "$msg"
478 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
479 $cmd_chmod u+rw "${gsdlhome}/bin"
480
481 msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}/bin/windows\"]"
482 echo "$msg"
483 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
484 $cmd_mkdir "${gsdlhome}/bin/windows"
485
486 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/Windows/bin/windows/netscape\" \"${gsdlhome}/bin/windows\"]"
487 echo "$msg"
488 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
489 $cmd_cpr "${cd_dir}/Windows/bin/windows/netscape" "${gsdlhome}/bin/windows"
490
491 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/Windows/bin/windows/Win32s\" \"${gsdlhome}/bin/windows\"]"
492 echo "$msg"
493 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
494 $cmd_cpr "${cd_dir}/Windows/bin/windows/Win32s" "${gsdlhome}/bin/windows"
495
496 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/Windows/bin/windows/net16\" \"${gsdlhome}/bin/windows\"]"
497 echo "$msg"
498 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
499 $cmd_cpr "${cd_dir}/Windows/bin/windows/net16" "${gsdlhome}/bin/windows"
500
501 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/Windows/bin/windows/net32\" \"${gsdlhome}/bin/windows\"]"
502 echo "$msg"
503 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
504 $cmd_cpr "${cd_dir}/Windows/bin/windows/net32" "${gsdlhome}/bin/windows"
505
506 msg="--> Install.sh: [$cmd_cp \"${cd_dir}/Windows/bin/windows/server.exe\" \"${gsdlhome}/bin/windows\"]"
507 echo "$msg"
508 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
509 $cmd_cp "${cd_dir}/Windows/bin/windows/server.exe" "${gsdlhome}/bin/windows"
510
511 msg="--> Install.sh: [$cmd_cp \"${cd_dir}/Windows/bin/windows/gssetup.exe\" \"${gsdlhome}/bin/windows\"]"
512 echo "$msg"
513 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
514 $cmd_cp "${cd_dir}/Windows/bin/windows/gssetup.exe" "${gsdlhome}/bin/windows"
515
516 msg="--> Install.sh: [$cmd_cp \"${cd_dir}/Windows/bin/windows/setpw.exe\" \"${gsdlhome}/bin/windows\"]"
517 echo "$msg"
518 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
519 $cmd_cp "${cd_dir}/Windows/bin/windows/setpw.exe" "${gsdlhome}/bin/windows"
520
521 msg="--> Install.sh: [$cmd_cp \"${cd_dir}/Windows/bin/windows/Setup.exe\" \"${gsdlhome}/bin/windows\"]"
522 echo "$msg"
523 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
524 $cmd_cp "${cd_dir}/Windows/bin/windows/Setup.exe" "${gsdlhome}/bin/windows"
525fi
526
527
528# which collections do we want
529cd "${cd_dir}/collect"
530echo "$itext13"
531echo "$itext13" >> "${gsdlhome}/INSTALL_RECORD"
532printf "%s" "> "
533read ans
534echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
535if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
536
537 # gsarch
538 echo "$itext14"
539 echo "$itext14" >> "${gsdlhome}/INSTALL_RECORD"
540 printf "%s" "> "
541 read ans
542 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
543 if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
544
545 msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}/collect/gsarch\"]"
546 echo "$msg"
547 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
548 $cmd_mkdir "${gsdlhome}/collect/gsarch"
549
550 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/gsarch/etc\" \"${gsdlhome}/collect/gsarch\"]"
551 echo "$msg"
552 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
553 $cmd_cpr "${cd_dir}/collect/gsarch/etc" "${gsdlhome}/collect/gsarch"
554
555 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/gsarch/images\" \"${gsdlhome}/collect/gsarch\"]"
556 echo "$msg"
557 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
558 $cmd_cpr "${cd_dir}/collect/gsarch/images" "${gsdlhome}/collect/gsarch"
559
560 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/gsarch/index\" \"${gsdlhome}/collect/gsarch\"]"
561 echo "$msg"
562 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
563 $cmd_cpr "${cd_dir}/collect/gsarch/index" "${gsdlhome}/collect/gsarch"
564 fi
565
566 # wordpdf
567 echo "$itext15"
568 echo "$itext15" >> "${gsdlhome}/INSTALL_RECORD"
569 printf "%s" "> "
570 read ans
571 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
572 if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
573
574 msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}/collect/wordpdf\"]"
575 echo "$msg"
576 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
577 $cmd_mkdir "${gsdlhome}/collect/wordpdf"
578
579 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/wordpdf/etc\" \"${gsdlhome}/collect/wordpdf\"]"
580 echo "$msg"
581 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
582 $cmd_cpr "${cd_dir}/collect/wordpdf/etc" "${gsdlhome}/collect/wordpdf"
583
584 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/wordpdf/images\" \"${gsdlhome}/collect/wordpdf\"]"
585 echo "$msg"
586 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
587 $cmd_cpr "${cd_dir}/collect/wordpdf/images" "${gsdlhome}/collect/wordpdf"
588
589 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/wordpdf/index\" \"${gsdlhome}/collect/wordpdf\"]"
590 echo "$msg"
591 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
592 $cmd_cpr "${cd_dir}/collect/wordpdf/index" "${gsdlhome}/collect/wordpdf"
593 fi
594
595 # chinese
596 echo "$itext16"
597 echo "$itext16" >> "${gsdlhome}/INSTALL_RECORD"
598 printf "%s" "> "
599 read ans
600 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
601 if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
602
603 msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}/collect/chinese\"]"
604 echo "$msg"
605 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
606 $cmd_mkdir "${gsdlhome}/collect/chinese"
607
608 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/chinese/etc\" \"${gsdlhome}/collect/chinese\"]"
609 echo "$msg"
610 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
611 $cmd_cpr "${cd_dir}/collect/chinese/etc" "${gsdlhome}/collect/chinese"
612
613 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/chinese/images\" \"${gsdlhome}/collect/chinese\"]"
614 echo "$msg"
615 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
616 $cmd_cpr "${cd_dir}/collect/chinese/images" "${gsdlhome}/collect/chinese"
617
618 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/chinese/index\" \"${gsdlhome}/collect/chinese\"]"
619 echo "$msg"
620 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
621 $cmd_cpr "${cd_dir}/collect/chinese/index" "${gsdlhome}/collect/chinese"
622 fi
623
624 # hdlsub
625 echo "$itext17"
626 echo "$itext17" >> "${gsdlhome}/INSTALL_RECORD"
627 printf "%s" "> "
628 read ans
629 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
630 if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
631
632 msg="--> Install.sh: [$cmd_mkdir \"${gsdlhome}/collect/hdlsub\"]"
633 echo "$msg"
634 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
635 $cmd_mkdir "${gsdlhome}/collect/hdlsub"
636
637 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/hdlsub/etc\" \"${gsdlhome}/collect/hdlsub\"]"
638 echo "$msg"
639 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
640 $cmd_cpr "${cd_dir}/collect/hdlsub/etc" "${gsdlhome}/collect/hdlsub"
641
642 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/hdlsub/images\" \"${gsdlhome}/collect/hdlsub\"]"
643 echo "$msg"
644 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
645 $cmd_cpr "${cd_dir}/collect/hdlsub/images" "${gsdlhome}/collect/hdlsub"
646
647 msg="--> Install.sh: [$cmd_cpr \"${cd_dir}/collect/hdlsub/index\" \"${gsdlhome}/collect/hdlsub\"]"
648 echo "$msg"
649 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
650 $cmd_cpr "${cd_dir}/collect/hdlsub/index" "${gsdlhome}/collect/hdlsub"
651 fi
652fi
653
654# set permissions
655msg="
656$itext18
657--> Install.sh: [$cmd_chmod -R u+rw \"$gsdlhome\"]
658--> Install.sh: [$cmd_chmod a+x \"${gsdlhome}/bin/script/\"*]"
659echo "$msg"
660echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
661$cmd_chmod -R u+rw "$gsdlhome"
662$cmd_chmod a+x "${gsdlhome}/bin/script/"*
663
664# certain files in gsdl/etc need to be globally writable
665msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/errout.txt\"]"
666echo "$msg"
667echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
668$cmd_chmod a+w "$gsdlhome/etc/errout.txt"
669msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/initout.txt\"]"
670echo "$msg"
671echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
672$cmd_chmod a+w "$gsdlhome/etc/initout.txt"
673msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/key.db\"]"
674echo "$msg"
675echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
676$cmd_chmod a+w "$gsdlhome/etc/key.db"
677msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/users.db\"]"
678echo "$msg"
679echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
680$cmd_chmod a+w "$gsdlhome/etc/users.db"
681msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/main.cfg\"]"
682echo "$msg"
683echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
684$cmd_chmod a+w "$gsdlhome/etc/main.cfg"
685msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/history.db\"]"
686echo "$msg"
687echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
688$cmd_chmod a+w "$gsdlhome/etc/history.db"
689msg="--> Install.sh: [$cmd_chmod a+w \"$gsdlhome/etc/usage.txt\"]"
690echo "$msg"
691echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
692$cmd_chmod a+w "$gsdlhome/etc/usage.txt"
693
694
695# should gsdl/collect and gsdl/tmp be globally writable?
696echo "$itext19"
697echo "$itext19" >> "${gsdlhome}/INSTALL_RECORD"
698printf "%s" "> "
699read ans
700echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
701if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
702 msg="--> Install.sh: [$cmd_chmod -R a+w \"$gsdlhome/collect\"]"
703 echo "$msg"
704 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
705 $cmd_chmod -R a+w "$gsdlhome/collect"
706 msg="--> Install.sh: [$cmd_chmod -R a+w \"$gsdlhome/tmp\"]"
707 echo "$msg"
708 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
709 $cmd_chmod -R a+w "$gsdlhome/tmp"
710fi
711
712# binaries or source code?
713compile="yes"
714if [ "$gsdlos" = "linux" ]; then
715 echo "$itext20"
716 echo "$itext20" >> "${gsdlhome}/INSTALL_RECORD"
717
718 found=no
719 while [ "$found" = "no" ]; do
720 echo "$itext21"
721 echo "$itext21" >> "${gsdlhome}/INSTALL_RECORD"
722 printf "%s" "> "
723 read ans
724 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
725 if [ "$ans" = "" ] || [ "$ans" = "b" ]; then
726 compile="no"
727 # install binaries
728 msg="
729$itext22
730--> Install.sh: [$cmd_cpr \"${cd_dir}/Unix/bin/linux\" \"${gsdlhome}/bin\" ]"
731 echo "$msg"
732 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
733 $cmd_cpr "${cd_dir}/Unix/bin/linux" "${gsdlhome}/bin"
734 msg="--> Install.sh: [$cmd_chmod a+x \"${gsdlhome}/bin/linux/\"*]"
735 echo "$msg"
736 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
737 $cmd_chmod a+x "${gsdlhome}/bin/linux/"*
738 msg="--> Install.sh: [$cmd_chmod -R u+rw \"${gsdlhome}/bin/linux\"]"
739 echo "$msg"
740 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
741 $cmd_chmod -R u+rw "${gsdlhome}/bin/linux"
742
743 # move library executable to cgi-bin
744 msg="--> Install.sh: [$cmd_mv \"${gsdlhome}/bin/linux/library\" \"${gsdlhome}/cgi-bin\"]"
745 echo "$msg"
746 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
747 $cmd_mv "${gsdlhome}/bin/linux/library" "${gsdlhome}/cgi-bin"
748
749 found="yes"
750 elif [ "$ans" = "c" ]; then
751 found="yes"
752 fi
753 done
754fi
755
756if [ "$compile" = "yes" ]; then
757 # install source
758 msg="
759$itext23
760--> Install.sh [$cmd_cpr \"${cd_dir}/src/lib\" \"$gsdlhome\"]"
761 echo "$msg"
762 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
763 $cmd_cpr "${cd_dir}/src/lib" "$gsdlhome"
764 msg="--> Install.sh [$cmd_cpr \"${cd_dir}/src/packages\" \"$gsdlhome\"]"
765 echo "$msg"
766 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
767 $cmd_cpr "${cd_dir}/src/packages" "$gsdlhome"
768 msg="--> Install.sh [$cmd_cpr \"${cd_dir}/src/src\" \"$gsdlhome\"]"
769 echo "$msg"
770 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
771 $cmd_cpr "${cd_dir}/src/src" "$gsdlhome"
772 msg="--> Install.sh [$cmd_cpr \"${cd_dir}/src/Unix/\"* \"$gsdlhome\"]"
773 echo "$msg"
774 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
775 $cmd_cpr "${cd_dir}/src/Unix/"* "$gsdlhome"
776 msg="--> Install.sh [$cmd_cp \"${cd_dir}/src/Install.txt\" \"$gsdlhome\"]"
777 echo "$msg"
778 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
779 $cmd_cp "${cd_dir}/src/Install.txt" "$gsdlhome"
780 msg="--> Install.sh: [$cmd_chmod -R u+rw \"$gsdlhome\"]"
781 echo "$msg"
782 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
783 $cmd_chmod -R u+rw "$gsdlhome"
784 msg="--> Install.sh: [$cmd_chmod a+x \"${gsdlhome}/configure\"]"
785 echo "$msg"
786 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
787 $cmd_chmod a+x "${gsdlhome}/configure"
788 msg="--> Install.sh: [$cmd_chmod a+x \"${gsdlhome}/packages/yaz/configure\"]"
789 echo "$msg"
790 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
791 $cmd_chmod a+x "${gsdlhome}/packages/yaz/configure"
792
793 # compile it
794 msg="--> Install.sh: [cd $gsdlhome]"
795 echo "$msg"
796 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
797 cd "$gsdlhome"
798 msg="$itext24
799
800--> Install.sh: [./configure]"
801 echo "$msg"
802 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
803 ./configure
804 msg="$itext25
805
806--> Install.sh: [make]"
807 echo "$msg"
808 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
809 make
810 msg="$itext26
811
812--> Install.sh: [make install]"
813 echo "$msg"
814 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
815 make install
816 msg="--> Install.sh: [cd $thisdir]"
817 echo "$msg"
818 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
819 cd "$thisdir"
820
821 # check that things compiled ok
822 if [ ! -f "${gsdlhome}/cgi-bin/library" ]; then
823 msg="$itext27
824$itext0
825$itext37"
826 echo "$msg"
827 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
828 exit 1
829 fi
830fi
831
832
833# try to find out hostname
834if [ "$gsdlos" = "linux" ]; then
835 hostname=`hostname -f`
836 if [ "$hostname" = "" ]; then
837 hostname=`hostname -i`
838 fi
839fi
840if [ "$hostname" = "" ]; then
841 hostname=`hostname`
842fi
843if [ "$hostname" = "" ]; then
844 hostname="your-computer-name"
845fi
846
847
848# get cgi-bin directory
849echo "$itext28"
850echo "$itext28" >> "${gsdlhome}/INSTALL_RECORD"
851if [ "$logname" != "root" ]; then
852 echo "$itext29"
853 echo "$itext29" >> "${gsdlhome}/INSTALL_RECORD"
854fi
855echo "$itext30"
856echo "$itext30" >> "${gsdlhome}/INSTALL_RECORD"
857if [ "$logname" != "root" ]; then
858 echo "$itext31"
859 echo "$itext31" >> "${gsdlhome}/INSTALL_RECORD"
860fi
861found=no
862remind_cgi="no"
863remind_cgi_nomove="no"
864while [ "$found" = "no" ]; do
865 echo "$itext32"
866 echo "$itext32" >> "${gsdlhome}/INSTALL_RECORD"
867 printf "%s" "> "
868 read ans
869 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
870 if [ "$ans" = "" ] || [ "$ans" = "1" ]; then
871 found="option1"
872 cgi_bin="${gsdlhome}/cgi-bin"
873 # default gsdl cgi-bin, do nothing
874 echo "$itext33"
875 echo "$itext33" >> "${gsdlhome}/INSTALL_RECORD"
876 remind_cgi="yes"
877 elif [ "$ans" = "2" ]; then
878 found="option2"
879 # external cgi-bin
880 echo "$itext34"
881 echo "$itext34" >> "${gsdlhome}/INSTALL_RECORD"
882 printf "%s" "> "
883 read ans
884 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
885 if [ "$ans" = "" ]; then
886 cgi_bin="/usr/local/apache/cgi-bin"
887 else
888 cgi_bin="$ans"
889 fi
890 if [ ! -d "$cgi_bin" ]; then
891 echo "$itext35"
892 echo "$itext35" >> "${gsdlhome}/INSTALL_RECORD"
893 printf "%s" "> "
894 read ans
895 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
896 if [ "$ans" = "" ] || [ "$ans" = "y" ]; then
897 msg="--> Install.sh: [$cmd_mkdir \"$cgi_bin\"]"
898 echo "$msg"
899 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
900 $cmd_mkdir "$cgi_bin"
901 if [ -d "$cgi_bin" ]; then
902 echo "$itext36"
903 echo "$itext36" >> "${gsdlhome}/INSTALL_RECORD"
904 remind_cgi="yes"
905 else
906 msg="$itext38
907$itext0
908$itext37"
909 echo "$msg"
910 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
911 exit 1
912 fi
913 fi
914 fi
915
916 if [ ! -w "$cgi_bin" ]; then
917 echo "$itext39"
918 echo "$itext39" >> "${gsdlhome}/INSTALL_RECORD"
919 remind_cgi_nomove="yes"
920 else
921 # install cgi-bin stuff (update the uninstall script first)
922 cd "$gsdlhome"
923 echo "#!/bin/sh" > Uninstall.sh
924 echo "" >> Uninstall.sh
925 echo "$cmd_rm \"${cgi_bin}/gsdlsite.cfg\"" >> Uninstall.sh
926 echo "$cmd_rm \"${cgi_bin}/library\"" >> Uninstall.sh
927 echo "echo \"remove ${gsdlhome} directory? [y]\"" >> Uninstall.sh
928 echo "read ans" >> Uninstall.sh
929 echo "if [ \"\$ans\" = \"\" ] || [ \"\$ans\" = \"y\" ]; then" >> Uninstall.sh
930 echo " $cmd_rmr \"$gsdlhome\"" >> Uninstall.sh
931 echo "fi" >> Uninstall.sh
932 $cmd_chmod u+x Uninstall.sh
933 cd "$thisdir"
934
935 msg="$itext40
936--> Install.sh: [$cmd_mv \"${gsdlhome}/cgi-bin/gsdlsite.cfg\" \"$cgi_bin\"]"
937 echo "$msg"
938 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
939 $cmd_mv "${gsdlhome}/cgi-bin/gsdlsite.cfg" "$cgi_bin"
940 msg="--> Install.sh: [$cmd_mv \"${gsdlhome}/cgi-bin/library\" \"$cgi_bin\"]"
941 echo "$msg"
942 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
943 $cmd_mv "${gsdlhome}/cgi-bin/library" "$cgi_bin"
944 fi
945 fi
946done
947
948# web address of cgi-bin
949web_cgi="http://${hostname}/cgi-bin"
950if [ "$found" = "option1" ]; then
951 web_cgi="http://${hostname}/gsdl/cgi-bin"
952fi
953echo "$itext41"
954echo "$itext41" >> "${gsdlhome}/INSTALL_RECORD"
955printf "%s" "> "
956read ans
957echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
958if [ "$ans" != "" ]; then
959 web_cgi="$ans"
960fi
961
962# get public_html directory
963echo "$itext42"
964echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
965if [ "$logname" != "root" ]; then
966 echo "$itext29"
967 echo "$itext29" >> "${gsdlhome}/INSTALL_RECORD"
968fi
969echo "$itext43"
970echo "$itext43" >> "${gsdlhome}/INSTALL_RECORD"
971if [ "$logname" != "root" ]; then
972 echo "$itext44"
973 echo "$itext44" >> "${gsdlhome}/INSTALL_RECORD"
974fi
975echo "$itext45"
976echo "$itext45" >> "${gsdlhome}/INSTALL_RECORD"
977found="no"
978remind_ph="no"
979remind_ph_nolink="no"
980while [ "$found" = "no" ]; do
981 echo "$itext32"
982 echo "$itext32" >> "${gsdlhome}/INSTALL_RECORD"
983 printf "%s" "> "
984 read ans
985 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
986 if [ "$ans" = "" ] || [ "$ans" = "1" ]; then
987 found="yes"
988 public_html="$gsdlhome"
989 # no link
990 echo "$itext46"
991 echo "$itext46" >> "${gsdlhome}/INSTALL_RECORD"
992 remind_ph="yes"
993 elif [ "$ans" = "2" ]; then
994 found="yes"
995 # external public_html
996 echo
997 public_html="/home/${logname}/public_html"
998 if [ "$logname" = "root" ]; then
999 public_html="/usr/local/apache/htdocs"
1000 fi
1001 echo "$itext47"
1002 echo "$itext47" >> "${gsdlhome}/INSTALL_RECORD"
1003 printf "%s" "> "
1004 read ans
1005 echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
1006 if [ "$ans" != "" ]; then
1007 public_html="$ans"
1008 fi
1009 # create link to gsdl (and update Uninstall.sh)
1010 if [ -w "$public_html" ]; then
1011 cd "$gsdlhome"
1012 echo "#!/bin/sh" > Uninstall.sh
1013 echo "" >> Uninstall.sh
1014 echo "$cmd_rm \"$public_html/gsdl\"" >> Uninstall.sh
1015 echo "$cmd_rm \"${cgi_bin}/gsdlsite.cfg\"" >> Uninstall.sh
1016 echo "$cmd_rm \"${cgi_bin}/library\"" >> Uninstall.sh
1017 echo "echo \"remove ${gsdlhome} directory? [y]\"" >> Uninstall.sh
1018 echo "read ans" >> Uninstall.sh
1019 echo "if [ \"\$ans\" = \"\" ] || [ \"\$ans\" = \"y\" ]; then" >> Uninstall.sh
1020 echo " $cmd_rmr \"$gsdlhome\"" >> Uninstall.sh
1021 echo "fi" >> Uninstall.sh
1022 $cmd_chmod u+x Uninstall.sh
1023 cd "$thisdir"
1024
1025 msg="--> Install.sh: [cd \"$public_html\"]"
1026 echo "$msg"
1027 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
1028 cd "$public_html"
1029 msg="--> Install.sh: [$cmd_ln \"$gsdlhome\" gsdl]"
1030 echo "$msg"
1031 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
1032 $cmd_ln "$gsdlhome" gsdl
1033 msg="--> Install.sh: [cd \"$thisdir\"]"
1034 echo "$msg"
1035 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
1036 cd "$thisdir"
1037 else
1038 echo "$itext48"
1039 echo "$itext48" >> "${gsdlhome}/INSTALL_RECORD"
1040 old_ph=$public_html
1041 remind_ph_nolink="yes"
1042 fi
1043 public_html="${public_html}/gsdl"
1044 fi
1045done
1046
1047
1048# get httpprefix
1049echo "$itext49"
1050echo "$itext49" >> "${gsdlhome}/INSTALL_RECORD"
1051printf "%s" ">"
1052httpprefix="/gsdl"
1053read ans
1054echo "> $ans" >> "${gsdlhome}/INSTALL_RECORD"
1055if [ "$ans" != "" ]; then
1056 httpprefix="$ans"
1057fi
1058
1059# get initial password
1060echo "$itext50"
1061echo "$itext50" >> "${gsdlhome}/INSTALL_RECORD"
1062pw=`${gsdlhome}/bin/${gsdlos}/getpw`
1063tmp="[admin]
1064<comment>
1065<enabled>true
1066<groups>administrator,colbuilder
1067<password>${pw}
1068<username>admin
1069----------------------------------------------------------------------"
1070echo "$tmp" | ${gsdlhome}/bin/${gsdlos}/txt2db "${gsdlhome}/etc/users.db"
1071$cmd_chmod a+rw "${gsdlhome}/etc/users.db"
1072
1073# edit gsdlsite.cfg
1074cd "$cgi_bin"
1075sed "s|\(gsdlhome *\)[^ ]*|\1${gsdlhome}|" gsdlsite.cfg > tmp123.txt && $cmd_mv tmp123.txt gsdlsite.cfg
1076sed "s|#*\(httpprefix *\)[^ ]*|\1${httpprefix}|" gsdlsite.cfg > tmp123.txt && $cmd_mv tmp123.txt gsdlsite.cfg
1077sed "s|\(httpimg *\)[^ ]*|\1${httpprefix}/images|" gsdlsite.cfg > tmp123.txt && $cmd_mv tmp123.txt gsdlsite.cfg
1078
1079# success
1080echo "$itext51"
1081echo "$itext51" >> "${gsdlhome}/INSTALL_RECORD"
1082if [ "$remind_cgi" = "yes" ]; then
1083 echo "$itext52"
1084 echo "$itext52" >> "${gsdlhome}/INSTALL_RECORD"
1085
1086 apache_web_cgi=`echo "$web_cgi" | sed "s|[^/]*//[^/]*||" | sed "s|/*$|/|"`
1087 cgi_bin_slash=`echo "$cgi_bin" | sed "s|/*$|/|"`
1088 cgi_bin_noslash=`echo "$cgi_bin" | sed "s|/*$||"`
1089
1090 msg="$itext53
1091
1092 ScriptAlias ${apache_web_cgi} \"${cgi_bin_slash}\"
1093 <Directory \"${cgi_bin_noslash}\">
1094 AllowOverride None
1095 Options None
1096 Order allow,deny
1097 Allow from all
1098 </Directory>
1099"
1100 echo "$msg"
1101 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
1102fi
1103if [ "$remind_cgi_nomove" = "yes" ]; then
1104 echo "$itext54"
1105 echo "$itext54" >> "${gsdlhome}/INSTALL_RECORD"
1106fi
1107if [ "$remind_ph" = "yes" ]; then
1108 echo "$itext55"
1109 echo "$itext55" >> "${gsdlhome}/INSTALL_RECORD"
1110
1111 apache_httpprefix=`echo "$httpprefix" | sed "s|[^/]*//[^/]*||" | sed "s|/*$|/|"`
1112 public_html_slash=`echo "$public_html" | sed "s|/*$|/|"`
1113 public_html_noslash=`echo "$public_html" | sed "s|/*$||"`
1114
1115 msg="$itext56
1116
1117 Alias ${apache_httpprefix} \"${public_html_slash}\"
1118 <Directory \"${public_html_noslash}\">
1119 Options Indexes MultiViews FollowSymLinks
1120 AllowOverride None
1121 Order allow,deny
1122 Allow from all
1123 </Directory>
1124"
1125 echo "$msg"
1126 echo "$msg" >> "${gsdlhome}/INSTALL_RECORD"
1127fi
1128if [ "$remind_ph_nolink" = "yes" ]; then
1129 echo "$itext57"
1130 echo "$itext57" >> "${gsdlhome}/INSTALL_RECORD"
1131fi
1132echo "$itext58"
1133echo "$itext58" >> "${gsdlhome}/INSTALL_RECORD"
1134
1135exit 0
Note: See TracBrowser for help on using the repository browser.