Rev | Line | |
---|
[1] | 1 | #!/bin/sh |
---|
| 2 | |
---|
| 3 | # Codebase installation script accompanies wwwsync to help install |
---|
| 4 | # of codebase enabled sites. |
---|
| 5 | # Quinn Comendant <quinn@strangecode.com> 25 Dec 2004 |
---|
| 6 | |
---|
| 7 | sitebase=`expr $0 : "\(.*\)/codebase/bin/install.sh"`; |
---|
| 8 | |
---|
| 9 | # Ensure log directory exists and is writable. |
---|
| 10 | if [ ! -d "$sitebase/log" ]; then |
---|
| 11 | mkdir "$sitebase/log"; |
---|
| 12 | fi |
---|
| 13 | chmod 777 "$sitebase/log"; |
---|
| 14 | |
---|
| 15 | # If old log locations exists, copy to new directory. |
---|
[52] | 16 | #if [ -f "$sitebase/codebase/logs/app_error_log" ] || [ -f "$sitebase/codebase/logs/php_error_log" ]; then |
---|
| 17 | if [ `ls -1 $sitebase/codebase/logs/ | wc -l` -gt 0 ]; then |
---|
[1] | 18 | echo "Moving logs to new log directory: $sitebase/log/"; |
---|
[52] | 19 | mv -vfb $sitebase/codebase/logs/* $sitebase/log/; |
---|
[1] | 20 | fi |
---|
| 21 | |
---|
| 22 | # Write site install date. |
---|
| 23 | echo `date '+%Y-%m-%d %H:%M:%S'` >> "$sitebase/wwwsynclog"; |
---|
Note: See
TracBrowser
for help on using the repository browser.