Author: carlos
Date: Tue Feb 19 18:29:35 2008
New Revision: 629321

URL: http://svn.apache.org/viewvc?rev=629321&view=rev
Log:
Everything is ready to run in the new configuration

Added:
    maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh   (with 
props)
Removed:
    maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize.sh
Modified:
    maven/archiva/tools/trunk/maven-meeper/src/bin/README.txt
    maven/archiva/tools/trunk/maven-meeper/src/bin/crontab.txt
    
maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize/m2-sync/sync.properties

Modified: maven/archiva/tools/trunk/maven-meeper/src/bin/README.txt
URL: 
http://svn.apache.org/viewvc/maven/archiva/tools/trunk/maven-meeper/src/bin/README.txt?rev=629321&r1=629320&r2=629321&view=diff
==============================================================================
--- maven/archiva/tools/trunk/maven-meeper/src/bin/README.txt (original)
+++ maven/archiva/tools/trunk/maven-meeper/src/bin/README.txt Tue Feb 19 
18:29:35 2008
@@ -5,67 +5,47 @@
 
 # Explanation of files found within maven-meeper
 
+crontab.txt has the crontab entries necessary to make everything run
+
 ##########################
-# One-button synchronizing
+# Maven 2 synchronizing
 ##########################
 
-## Script to synchronize m1 repositories, convert them to m2, fix them, 
-## sync the m2 repositories to ibiblio and update the mod_rewrite rules
-./synchronize.sh
+In ./synchronize/m2-sync
+
+## Uses the java code in 
https://svn.apache.org/repos/asf/maven/archiva/tools/trunk/maven-meeper
+java -jar maven-meeper-1-SNAPSHOT-jar-with-dependencies.jar sync.properties 
sync.csv
 
-## Configuration for the above
-./synchronize.properties
+## sync.properties has the configuration options
+## sync.csv has the list of repositorios that get synced
 
 ####################################################
 # Upload bundles from the Maven JIRA to a repository
 ####################################################
 
-## dos2unix function
-./bundle-upload/d2u
-
 ## See: http://maven.apache.org/guides/mini/guide-ibiblio-upload.html
 ## Pulls a bundle down via wget, deploys jar, pom, license file, java-sources, 
javadocs
 ./bundle-upload/deploy-bundle
 
 ##############################################
-# Convert an m1 repository to an m2 repository
+# Sync to primary mirrors
 ##############################################
 
-## java.net uses CVS and only certain parts need to be synced.
-./m1-m2-conversion/java.net/sync-repoclean.sh
+## rsyncs the central m2 repository over to the cica.es mirror
+./sync-central-to-cica.sh synchronize.properties
 
-## configuration for the above
-./m1-m2-conversion/java.net/synchronize.properties
-
-## Uses 
http://svn.apache.org/repos/asf/maven/sandbox/repoclean/src/main/bash/repoclean.sh
-## which runs Java code to do the bulk of the work.
-./m1-m2-conversion/sync-repoclean.sh
+## rsyncs the central m2 repository over to the ibiblio mirror
+./sync-central-to-ibiblio.sh synchronize.properties
 
-## configuration for the above
-./m1-m2-conversion/synchronize.properties
 
-## Maven 1 -> Maven 2 mod-rewriting
-./synchronize/m1-m2-mod-rewrite-rules.txt
+##################################################
+# Maven 1
+##################################################
 
-## rsyncs from an m2 repository somewhere onto a subdirectory of 
-## the central repository. By choosing the subdirectory, some security is 
ensured.
-./synchronize/m2-sync/m2-sync.sh
-
-## Bash scripts that set variables to be used by the above script
-./synchronize/m2-sync/conf/codehaus.sh
-./synchronize/m2-sync/conf/displaytag.sh
-./synchronize/m2-sync/conf/net.databinder.sh
-./synchronize/m2-sync/conf/net.sourceforge.jwebunit.sh
-./synchronize/m2-sync/conf/net.sourceforge.maven-taglib.sh
-./synchronize/m2-sync/conf/org.acegisecurity.sh
-./synchronize/m2-sync/conf/org.apache.sh
-./synchronize/m2-sync/conf/org.mortbay.sh
-./synchronize/m2-sync/conf/org.objectweb.sh
-./synchronize/m2-sync/conf/org.springframework.sh
-./synchronize/m2-sync/conf/wicket.sh
-
-## rsyncs the central m2 repository over to the ibiblio mirror
-./synchronize/sync-central-to-ibiblio.sh
+## all in one script
+./synchronize-m1.sh
+## and to update the rewrite rules
+./synchronize-rewrite-rules-to-ibiblio.sh synchronize.properties
 
 ##################################################
 # M1 synchronize from upstream repositories script
@@ -92,6 +72,21 @@
 
 ## top level configuration
 ./synchronize/syncopate/syncopate.conf
+
+##############################################
+# Convert an m1 repository to an m2 repository
+##############################################
+
+## Uses 
http://svn.apache.org/repos/asf/maven/sandbox/repoclean/src/main/bash/repoclean.sh
+## which runs Java code to do the bulk of the work.
+
+./m1-m2-conversion/sync-repoclean.sh
+
+## configuration for the above
+./m1-m2-conversion/synchronize.properties
+
+## Maven 1 -> Maven 2 mod-rewriting
+./synchronize/m1-m2-mod-rewrite-rules.txt
 
 ###############################
 # DELETE THESE IF INDEED UNUSED

Modified: maven/archiva/tools/trunk/maven-meeper/src/bin/crontab.txt
URL: 
http://svn.apache.org/viewvc/maven/archiva/tools/trunk/maven-meeper/src/bin/crontab.txt?rev=629321&r1=629320&r2=629321&view=diff
==============================================================================
--- maven/archiva/tools/trunk/maven-meeper/src/bin/crontab.txt (original)
+++ maven/archiva/tools/trunk/maven-meeper/src/bin/crontab.txt Tue Feb 19 
18:29:35 2008
@@ -1,4 +1,15 @@
 # Cron jobs for the maven repository
[EMAIL PROTECTED]
-0  */4 * * * cd $HOME/bin; ./kill_long_runners.sh rsync 3 && ./synchronize.sh
-0   0  * * * cd $HOME/reports; ./run.sh
+# try to make then run at pseudo-random hours and minutes to avoid high load 
[EMAIL PROTECTED]
+# sync m1 repos and convert to m2
+28 2,14 * * * cd $HOME/bin; ./synchronize-m1.sh
+# sync rewrite rules to m1 repo at ibiblio
+51 19 * * * cd $HOME/bin; ./synchronize-rewrite-rules-to-ibiblio.sh 
$HOME/bin/synchronize.properties
+# sync m2 repos
+16 0,4,8,12,16,20 * * * cd $HOME/bin/synchronize/m2-sync; java -jar 
maven-meeper-1-SNAPSHOT-jar-with-dependencies.jar sync.properties sync.csv
+# sync central to cica.es mirror
+30 1,5,9,13,17,21 * * * cd $HOME/bin; ./synchronize-central-to-cica.sh 
$HOME/bin/synchronize.properties
+# sync central to ibiblio
+5  3,11,20 * * * cd $HOME/bin; ./synchronize-central-to-ibiblio.sh 
$HOME/bin/synchronize.properties
+# run reports
+34 2  * * * cd $HOME/reports; ./run.sh

Added: maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh
URL: 
http://svn.apache.org/viewvc/maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh?rev=629321&view=auto
==============================================================================
--- maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh (added)
+++ maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh Tue Feb 19 
18:29:35 2008
@@ -0,0 +1,93 @@
+#!/bin/sh
+
+# ------------------------------------------------------------------------
+# 1. Sync Maven 1.x repositories to central
+# 2. Convert Maven 1.x repository to Maven 2.x repository
+# 3. Manual fixes
+# 4. Sync Maven 2.x repositories to central
+# 5. Sync the Maven 2.x repository to Cica and Ibiblio
+# 6. Copy the mod_rewrite rules to the Maven 1.x repository @ Ibiblio
+# ------------------------------------------------------------------------
+
+# check if script is already running
+PID=$$
+RUNNING=`ps -ef | grep synchronize.sh | grep -v 'sh -c' | grep -v grep | grep 
-v $PID`
+
+
+dir=`pwd`
+syncProperties=$dir/synchronize.properties
+source $syncProperties
+
+((
+
+MODE=$1
+
+echo "Using the following settings:"
+echo "CENTRAL_HOST = $CENTRAL_HOST"
+echo "TOOLS_BASE = $TOOLS_BASE"
+echo "SYNC_TOOLS = $SYNC_TOOLS"
+echo "SYNCOPATE = $SYNCOPATE"
+echo "REPOCLEAN = $REPOCLEAN"
+echo "M1_M2_REWRITE_RULES = $M1_M2_REWRITE_RULES"
+echo "SYNC_REPORTS = $SYNC_REPORTS"
+echo "JAVA = $JAVA"
+
+# exit if already running
+echo $RUNNING
+if [ ! -z "$RUNNING" ]; then
+  date >> $SYNC_REPORTS/synchronize.log
+  echo Sync already running... exiting >> $SYNC_REPORTS/synchronize.log
+  echo $RUNNING >> $SYNC_REPORTS/synchronize.log
+  exit 1
+fi
+
+
+[ "$MODE" = "batch" ] && echo && echo "Press any key to continue, or hit ^C to 
quit." && echo
+
+# ------------------------------------------------------------------------
+# Syncopate: Sync the Maven 1.x repositories 
+# ------------------------------------------------------------------------
+
+[ "$MODE" = "batch" ] && echo && echo "Press any key to run syncopate, or hit 
^C to quit." && echo
+
+echo ">>>>>>>>>>>>>>>>>> Running Syncopate"
+
+(
+  cd $SYNCOPATE
+  ./sync
+  retval=$?; if [ $retval != 0 ]; then exit $retval; fi
+)
+retval=$?; if [ $retval != 0 ]; then exit $retval; fi
+
+# ------------------------------------------------------------------------
+# Repoclean: converting the Maven 1.x repository to Maven 2.x 
+# ------------------------------------------------------------------------
+
+[ "$MODE" = "batch" ] && echo && echo "Press any key to run the m1 to m2 
conversion, or hit ^C to quit." && echo
+
+echo ">>>>>>>>>>>>>>>>>> Running Maven 1.x to Maven 2.x conversion ..."
+
+(
+  cd $REPOCLEAN
+  ./convert-m1-m2.sh $syncProperties
+  retval=$?; if [ $retval != 0 ]; then exit $retval; fi
+)
+retval=$?; if [ $retval != 0 ]; then exit $retval; fi
+
+# ------------------------------------------------------------------------
+# Manual fixes
+# ------------------------------------------------------------------------
+
+[ "$MODE" = "batch" ] && echo && echo "Press any key to run manual fixes, or 
hit ^C to quit." && echo
+
+echo ">>>>>>>>>>>>>>>>>> Removing commons-logging 1.1-dev"
+
+# hack prevent commons-logging-1.1-dev
+CL=$MAVEN2_REPO/commons-logging/commons-logging
+rm -rf $CL/1.1-dev
+grep -v 1.1-dev $CL/maven-metadata.xml > $CL/maven-metadata.xml.tmp
+mv $CL/maven-metadata.xml.tmp $CL/maven-metadata.xml
+md5sum $CL/maven-metadata.xml > $CL/maven-metadata.xml.md5
+sha1sum $CL/maven-metadata.xml > $CL/maven-metadata.xml.sha1
+
+) | tee $SYNC_REPORTS/last-sync-results.txt ) 2>&1

Propchange: maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh
------------------------------------------------------------------------------
    svn:executable = *

Propchange: maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize-m1.sh
------------------------------------------------------------------------------
    svn:keywords = "Author Date Id Revision"

Modified: 
maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize/m2-sync/sync.properties
URL: 
http://svn.apache.org/viewvc/maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize/m2-sync/sync.properties?rev=629321&r1=629320&r2=629321&view=diff
==============================================================================
--- 
maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize/m2-sync/sync.properties
 (original)
+++ 
maven/archiva/tools/trunk/maven-meeper/src/bin/synchronize/m2-sync/sync.properties
 Tue Feb 19 18:29:35 2008
@@ -1,9 +1,11 @@
-#dryRun=false
+# any other value will make it run the sync without actually copying files 
+dryRun=false
+
 exclusionsFile=/home/maven/bin/synchronize/syncopate/exclusions.txt
 basedir=/home/maven/repository-staging/to-ibiblio/maven2
 log=/tmp/sync-changed.log
 mailHostName=localhost
[EMAIL PROTECTED]
[EMAIL PROTECTED]
 [EMAIL PROTECTED]
 mailSubject=[Maven Central Repository Synchronization]
 mailFooter=This is an automated email, do not respond.\


Reply via email to