quelques bugs de moins
This commit is contained in:
@@ -8,11 +8,12 @@ DESTMAIL="contact@lalis.fr"
|
||||
FROMMAIL="root@lalis.fr"
|
||||
TASKRPM="task-lalis"
|
||||
MIRRORPATH="/mirror/mageia"
|
||||
MEDIAINFO_PATH="$MIRRORPATH/config_lalis"
|
||||
MSG=/tmp/mirror_mageia.mail
|
||||
#SERVEUR="rsync://fr2.rpmfind.net/linux/mageia"
|
||||
SERVEUR="rsync://fr2.rpmfind.net/linux/mageia"
|
||||
#SERVEUR="http://ftp.free.fr/mirrors/mageia.org"
|
||||
#SERVEUR="rsync://ftp.acc.umu.se/mirror/mageia/"
|
||||
SERVEUR="rsync://ftp.belnet.be/mageia"
|
||||
#SERVEUR="rsync://ftp.belnet.be/mageia"
|
||||
|
||||
|
||||
function title()
|
||||
@@ -42,23 +43,22 @@ iferror( ) #$RESULT, $TXT, $LINENO
|
||||
echo "Synchronisation miroirs Mageia"
|
||||
pidof -o %PPID -x -s mirror_mageia
|
||||
if [ $? -eq 0 ];then
|
||||
echo "" >$MSG
|
||||
info "mirror_mageia déjà lancé"
|
||||
echo "mirror_mageia déjà lancé"
|
||||
else
|
||||
#Mageia current version
|
||||
echo "" >$MSG
|
||||
echo "Subject: Synchro miroirs" >$MSG
|
||||
title "Synchronisation de Mageia $PRESENT"
|
||||
rsync -a -H -S -v --delete-after --delete-excluded --delay-updates --exclude="*testing" --exclude="*debug/" --exclude="SRPMS/" $SERVEUR/distrib/$PRESENT/ "$MIRRORPATH"/distrib/$PRESENT/
|
||||
if [ $? -eq 0 ]; then
|
||||
|
||||
cd "$MIRRORPATH"/distrib/$PRESENT
|
||||
cp $MIRRORPATH/media_info/"$PRESENT"_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
cp "$MEDIAINFO_PATH"/"$PRESENT"_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
iferror "$?" "Copie de "$PRESENT"_i586_media.cfg vers ./i586/media/media_info/media.cfg" $LINENO
|
||||
cp $MIRRORPATH/media_info/"$PRESENT"_x86_64_media.cfg ./x86_64/media/media_info/media.cf
|
||||
cp "$MEDIAINFO_PATH"/"$PRESENT"_x86_64_media.cfg ./x86_64/media/media_info/media.cf
|
||||
iferror "$?" "Copie de "$PRESENT"_x86_64_media.cfg vers ./x86_64/media/media_info/media.cfg" $LINENO
|
||||
cp "$MIRRORPATH"/$TASKRPM ./i586/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./i586/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./i586/media/core/release" $LINENO
|
||||
cp "$MIRRORPATH"/$TASKRPM ./x86_64/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./x86_64/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./x86_64/media/core/release" $LINENO
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./i586
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./x86_64
|
||||
@@ -87,13 +87,13 @@ else
|
||||
rsync -v -aHS --delete-after --delete-excluded --delay-updates --exclude=SRPMS/ --exclude "armv5tl/" --exclude=*testing --exclude="*debug/" $SERVEUR/distrib/cauldron/ "$MIRRORPATH"/distrib/cauldron/
|
||||
if [ $? -eq 0 ]; then
|
||||
cd "$MIRRORPATH"/distrib/cauldron
|
||||
cp "$MIRRORPATH"/config/media_info/cauldron_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
cp "$MEDIAINFO_PATH"/cauldron_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
iferror "$?" "Copie de cauldron_i586_media.cfg vers ./i586/media/media_info/media.cfg" $LINENO
|
||||
cp "$MIRRORPATH"/config/media_info/cauldron_x86_64_media.cfg ./x86_64/media/media_info/media.cfg
|
||||
cp "$MEDIAINFO_PATH"/cauldron_x86_64_media.cfg ./x86_64/media/media_info/media.cfg
|
||||
iferror "$?" "Copie de cauldron_x86_64_media.cfg vers ./x86_64/media/media_info/media.cfg" $LINENO
|
||||
cp "$MIRRORPATH"/task ./i586/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./i586/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./i586/media/core/release" $LINENO
|
||||
cp "$MIRRORPATH"/$TASKRPM ./x86_64/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./x86_64/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./x86_64/media/core/release" $LINENO
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./i586
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./x86_64
|
||||
@@ -118,13 +118,13 @@ else
|
||||
if [ $? -eq 0 ]; then
|
||||
|
||||
cd "$MIRRORPATH"/distrib/$OLD
|
||||
cp "$MIRRORPATH"/media_info/"$OLD"_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
cp "$MEDIAINFO_PATH"/"$OLD"_i586_media.cfg ./i586/media/media_info/media.cfg
|
||||
iferror "$?" "Copie de "$OLD"_i586_media.cfg vers ./i586/media/media_info/media.cfg" $LINENO
|
||||
cp "$MIRRORPATH"/media_info/"$OLD"_x86_64_media.cfg ./x86_64/media/media_info/media.cf
|
||||
cp "$MEDIAINFO_PATH"/"$OLD"_x86_64_media.cfg ./x86_64/media/media_info/media.cf
|
||||
iferror "$?" "Copie de "$OLD"_x86_64_media.cfg vers ./x86_64/media/media_info/media.cfg" $LINENO
|
||||
cp "$MIRRORPATH"/$TASKRPM ./i586/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./i586/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./i586/media/core/release" $LINENO
|
||||
cp "$MIRRORPATH"/$TASKRPM ./x86_64/media/core/release/
|
||||
cp "$MIRRORPATH/$TASKRPM"* ./x86_64/media/core/release/
|
||||
iferror "$?" "Copie de $TASKRPM vers ./x86_64/media/core/release" $LINENO
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./i586
|
||||
nice -n 19 gendistrib --nobadrpm --blind --skipmissingdir ./x86_64
|
||||
@@ -149,5 +149,5 @@ else
|
||||
#common
|
||||
chown $DEFUSER:$DEFGROUP -R "$MIRRORPATH"/distrib
|
||||
chmod a+rX -R "$MIRRORPATH"/distrib
|
||||
sendmail -f $FROMMAIL $DESTMAIL <$MSG
|
||||
fi
|
||||
sendmail -f $FROMMAIL $DESTMAIL <$MSG
|
||||
|
Reference in New Issue
Block a user