Changes between Version 2 and Version 3 of mirrors/httpstatic
- Timestamp:
- Jul 16, 2006, 7:09:38 PM (18 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
mirrors/httpstatic
v2 v3 12 12 * Options !FollowSymlinks Indexes 13 13 * 500MB free disk space 14 * crontab program or similar 14 15 15 Once you have the basics setup and ready to mirror, please contact Justin Knierim at admin@cross-lfs.org with the following info: 16 There is a script below which you can use to rsync the website and associated data to your mirror. We recommend syncing twice an hour, at random minutes. Once you have the mirror ready to go, please contact Justin Knierim at admin@cross-lfs.org with the information below. You can then be added to the mirrors list. Also should you have questions, feel free to ask. 16 17 17 18 * URL … … 20 21 * Contact Information (Name, Email Address) 21 22 22 He will then get back to you with the rsync script you need any can offer help with any questions you have. 23 == Website Rsync Scipt == 24 25 There are many ways to setup the rsync of the website. A basic bash script is shown below, which will rsync the website and email you should there be any errors: 26 27 {{{ 28 #!/bin/sh 29 30 SITE=cross-lfs.org 31 MODULE=clfs-www 32 LOCAL=/path/to/mirror # Change this value 33 USER=admin@domain.com # Change this value 34 MAILER=/usr/sbin/sendmail # Change this value 35 36 [ -d "$LOCAL" ] || mkdir -p $LOCAL 37 38 OUTPUT=`rsync -clprtv --delete ${SITE}::${MODULE} ${LOCAL} 2>&1` 39 40 if [ $? -ne 0 -o `echo -e "${OUTPUT}" | wc -l` -ne 4 ] ; then 41 (echo -e "Subject: cross-lfs.org mirror - Rsync Error\n"; echo -e "${OUTPUT}") | ${MAILER} ${USER}; 42 fi 43 }}} 44 45 The most basic would be just running the rsync command directly in cron or fcron: 46 47 {{{ 48 rsync -clprt --delete cross-lfs.org::clfs-www /path/to/mirror 49 }}} 23 50 24 51 [wiki:mirrors Go back to mirrors page]