on commence par ne traiter que ce qui nous concerne
authorWilly MANGA <willy.manga@auf.org>
Fri, 11 May 2012 07:24:27 +0000 (08:24 +0100)
committerWilly MANGA <willy.manga@auf.org>
Fri, 11 May 2012 07:24:27 +0000 (08:24 +0100)
scripts/redirectionUrl/squidRedirector

index 2aad6cd..b347ac2 100644 (file)
 #
 # ATTENTION : le miroir est incomplet => ne pas tout rediriger bêtement !!
 #
-MIRROR="cnf.vn.refer.org/mirror"
+MIRROR="miroir.ndere.cm.refer.org"
 while read URL CLIENT USER METHOD GROUP
 do
-  URL2="${URL/:\/\/apt.auf.org\//://${MIRROR}/auf/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/apt.hanoilug.org\/ubuntu\//://${MIRROR}/ubuntu/hanoilug/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/security.ubuntu.com\/ubuntu\//://${MIRROR}/ubuntu/security/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/archive.canonical.com\/ubuntu\//://${MIRROR}/ubuntu/canonical/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/*archive.ubuntu.com\/ubuntu\//://${MIRROR}/ubuntu/archive/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/*packages.medibuntu.org\//://${MIRROR}/ubuntu/medibuntu/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/security.debian.org\/debian-security\//://${MIRROR}/debian/security/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/security.debian.org\//://${MIRROR}/debian/security/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/volatile.debian.org\/debian-volatile\//://${MIRROR}/debian/volatile/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/ftp*.debian.org\/debian\//://${MIRROR}/debian/archive/}"
-  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/www.backports.org\/debian\//://${MIRROR}/debian/backports/}"
+  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/security.ubuntu.com\/ubuntu\//://${MIRROR}/ubuntu/}"
+  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/*archive.ubuntu.com\/ubuntu\//://${MIRROR}/ubuntu/}"
+  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/security.debian.org\//://${MIRROR}/debian-security/}"
+  [ "$URL2" = "$URL" ] && URL2="${URL/:\/\/ftp*.debian.org\/debian\//://${MIRROR}/debian/}"
   if [ "$URL2" != "$URL" ] && HEAD -t5 "$URL2" > /dev/null
   then
     echo "!mirror!$URL2"